I mean it is theft protection. My iPhone was stolen and I put it into lost mode and eventually got it back (the person who bought it and ended up with it called a phone number that appeared on it). If you could root it you could just steal iPhones and sell them to a fence who could bulk reset a bunch of devices or whatever. As far as I know, it basically means people won't bother stealing them.
Nobody legitimate is reselling used iPhones without resetting them first... because you have to reset them first.
Literally all you have to do is have the person who owns the device reset it.
https://support.apple.com/guide/iphone/erase-iphone-iph7a2a9399b/ios
https://support.apple.com/en-us/HT201351
It is literally one step. They have an FAQ page on how to do it lmao.
Like it is basically the equivalent of setting a password in your BIOS (if your motherboard didn't also have a full reset button).