Because men who are well out of highschool (up to maybe about 25) and date kids still in the school system/legally still under their parents authority are all stunted retards who are exploiting something about those kids in an uneven power relationship. Whether it's their own mental immaturity or because they like controlling someone with a half-formed sense of self and how to fit into the world.
If someone is over 30 and wants to date a highschooler, whether they are 18 or not, they are a predator. Something is wrong with them and they fetishize the power dynamic.
Laws exist as a simple codified version of more nuanced opinions in a complex society. And unfortunately an outsized amount of who has say in these laws are old religious men with money. That's why evangelicals can marry 13 year olds and why 16 is the AOC in a lot of states. I hope this explained something very basic, hopefully you can take leave from this epic battle of minds now and also kill yourself?