For me, I think the romantic appeal of what seems to be villainous/evil/cold MLs is that they are that way on the surface.
If they are truly 100% assholes all the way down to the bottom of their hearts, then I think that dips closer in true liking "bad boys" territory (which I personally kind of consider a distinct separate fetish), but I think a lot of instances part of the core appeal is the fact that these "bad" villains aren't as bad as they seem at first glance.
To pick out a few of the responses above, there's an idea of "gap moe" (@Loni4ever), that they'll "change for the better" (@Potatoes) and that the FL is "The One" (@Cuddles0_0) girl that the ML will treat differently.
I'm a fairly possessive, clingy, and jealous person when it comes to romantic things — which is pretty much the shoujo norm — but essentially I want to the kind of girl that is special to the ML. There are a lot of ways to be special, but a guy that hates women in general but has this one girl that he has fluttering feelings for is like a classic example. Consequently, using a villain in this kind of role is the most extreme version of this but works equally well. This is because if the villain is horrible to everyone but has his hearted warmed only by the FL, this is a level of special that is over 9000%. Main it's kind of a vain and extremely possessive way of thinking, but I still get the *dokidoki* from it.
Consequently, if you see girls raving about villains online, something to keep in mind is that often times we have headcanons (an unofficial version of off-screen events) privately between us that we're all raving about. BL subtext is a version of headcanon, but taking villains and making them into tragic bishie anti-heroes is another version of headcanon that I'm extremely guilty of doing allllll the time.
It isn't because I like rapists or murderers or evil demon lords in general — no definitely not!
However reading between the lines is something that has been an element of female romance for decades! For instance, consider the Disney classic Beauty and the Beast — appearances aren't the same as reality, and this theme pops up frequently in the stories that I read. A lot of female readers wouldn't bat an eye at an evil villainous "beast-like" ML for a romance story so long as the character is developed in his relationship to something that we like. In fact, some of us like to think (maybe erroneously?) that we're good at seeing through people, and characters that are good at seeing people's true hearts behind their superficial skin is another home run trope that I see a lot.
The other thing is that to really understand a lot of shoujo, I think it's necessary to consider self-image from the perspective of the girl.
Most of us aren't stunningly jade-like skin attractive, and an ML who likes the FL only for her appearance consequently gets a straight out F in my gradebook! It does nothing for me, and I think it's similar for a lot of readers. Consequently, it's necessary for the author to figure out how develop a sense of "true love" (lol I can't believe I'm saying this) between the ML and FL, understanding the fact that most girls have a level of insecurity with respect to a lot of things.
There are multiple common tropes for developing this "true love", depending on the story.
However, having a dark/evil ML is one potential avenue that commonly gets used. Particularly, you have an angelic MC (angelic in the sense that her soul is very pure and shiny) who comes and "saves" the ML through the virtue of her positive influence. It's kind of a savior complex thing (see my main account @yuzuki 's blog on white knights and the angel complex), and the result of this is that the ML ends up dependent on the FL even though she doesn't necessarily have too many otherwise stunning qualities. It's a very empowering and honeytrap feeling sentiment to have someone who needs you and wants you desperately, or that you are instrumental for everything that the ML does from his successes to failures.
In contrast, it's impossible to do this kind of thing with a perfect shining knight ML (e.g. Prince Charming), because a perfect ML has no deficiencies. There's no room for any FL to reflect onto the relationship, which basically means the FL is useless and no girl would really read a romance story about being a trophy girl. Those kinds of relationships are more common in stories written for a male audience novel.
In summary, there are multiple reasons why a dark / evil-esque ML has many opportunities for a very nosebleed-inducing romance for novels intended for young girls. That said — all of these things are horrible lessons for girls to take into reality, although unfortunately it legitimately does happen... resulting in situations like women not wanting to separate from abusive relationships because she thinks the guy will improve or that she'll be able to change the guy blahblah... which realistically doesn't happen so often except in fiction.