Mongodb e-commerce commodity property sheet design method?

students are doing a Wechat mall store, because there are different goods, each commodity has different attributes, that is, the attributes are not fixed. I have considered whether it is reasonable to design in this way:

//
{
-id:        ,
name:"",
descripe:"",
imgUrls:[],
details:[]
}

details put the product in different specifications, including inventory, price, and common name,descripe,imgUrls, uploaded by front-end users. Because the attribute of each uploaded item is not fixed, first let the user create attributes such as the item: color: 3, size: 3, and then js generates a list. According to the combination, 9 lists should be generated, and then the corresponding push specifications should be uploaded. Like this:
Color, size, price, stock quantity
blue 42 100 10
blue 41 110 15
.
..
then upload uniformly. Excuse me, is there any improvement in this design? I saw JD.com "s commodity with multiple attributes, which can be combined to produce more than one specification. How did JD.com design it? does details need to be divided into a separate table?

Jun.28,2021
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e7bb75-46642.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e7bb75-46642.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?