Left is her disguised form design. Right is her true form design
Backstory:
Cozy is indeed mainly the child of Chrysalis & Sombra, except neither of them are actually aware of her existence (as their child). In fact Sombra wasn't even currently alive / around at the time of Cozy's 'birth'. This is because it was actually discord who created Cozy from materials he had collected belonging to the other 2; this is tied into the fact that draconequus are born from eggs by coalescing magic from their parent sources. In this way, Discord was basically able to use magic traces + physical remnants plus some of his own magic to create the egg that had Cozy in it.
He was doing this as a part of a plan he was making, which did involve having a child on the inside he could use. The exact nature of this plan is unknown and fell through due to some unforeseen circumstances. When Cozy was born / hatched she looked closer to her shown true form (but not quite exactly, she had less cannon style Cozy & more just her parents traits) which wouldn't have worked for his plans so he used a combination of a changeling's innate ability to transform + come chaos magic to force & lock her into the disguise form.
The problem with this is 2 fold. One part is that he isn't really all that directly knowledgable about how changelings actually work so he kinda made a bit of a whoopsie which imprinted the disguise form more heavily onto her than it should be, which is how come she has some traits that don't really make sense with her parents. The second part is that even though Cozy was made through draconequus means she isn't really one & the amount of chaos magic he used wasn't too good for her in the long run. This chaos magic combined with her 'evil' parentage is the reason that in the show she seems so unrepentantly evil, it was kind of driving her a little mad.
The thing is the way Discord's plan was working involved him placing Cozy into the general pony population as an agent, so she ended up at an orphanage & then later adopted by a pony couple. During this time when she was growing up he didn't really check in on her, satisfied to just leave her until his plan called for her. Problem was when he next saw her she was nothing like he had expected (and needed). She had the manipulative 'evil' streak in her and was far more intelligent than he had planned for. When he was making his Grogar disguise plans he remember her and that's one of the reasons he was more than willing to take her on board. To kind of see first-hand what exactly had happened with his experiment child.
He does actually eventually admit to the whole debacle later down the line which is one of the biggest keys in people finally being willing to release her form the statue and attempt to reform her. The biggest advocates for this having been Trixie, Sunset & starlight, who end up adopting her once she is freed because her original parents didn't really want to or know how to deal with a child like Cozy. It's also once she's free that he release the magic binding her fully to her disguise form, which also helps Cozy because it gets rid of a large portion of the magic that was previously influencing her so heavily. I mean, she still needed help & therapy to overcome the damage done to her mind by the chaos magic. With this plus the support of her new mums she was able to reform and live a more peaceful & happy life (plus eventually find love and have kids of her own).
TL: DR. Discord used draconequus magic in an experiment to create a child of Chrysalis & Sombra. He had a plan for her which feel through due to some unexpected side-effects. Which was that the magic he used drove her kinda mad & 'evil'; making her the way she was on the show. With love & support she was able to recover from her trauma to live a happy life.