The age of consent in Korea is 16 (same as the UK). So many foreigners think it's 20, which is just incorrect. This is weirdly one of the most widely propogated pieces of misiniformation about Korea amongst foreigners, I have no idea where this came from.
So anyways, this isn't illegal at all. Like someone else said, probably he just dumped her because he's about to become a famous idol and this is her getting back at him. Is it really so unusual for a 19 year old to date a 17 year old?
Also, just to clear this up too, "19" was like the adult age under Korean age, but since June this year it's changed to just 18 international age (previously 19 years Korean age would be 17-18 international age). But lots of things like netflix or videogames, where age isn't actually a "law" just a recommendation, still are using Korean age because the vast majority of Koreans still use Korean age colloquially.