easiest example: most components of a macbook laptop have their serial number baked in the OS (or some hardware controller, idr). So even if you can find a legit macbook part from another laptop, and you can even replace it yourself (which is also impossible but that's another story), the laptop won't boot. In order for it to boot, you need a special device which "official apple repair" people have, which can bake-in the new part's serial number.
Security measure - otherwise someone can intercept your MacBook during delivery, replace the original component with a fake one that has a backdoor and ship it to you and you start using it completely oblivious to the fact it has been hacked.
That might be an argument to reject non-genuine components, but it's not an argument to reject genuine components just because they've previously been installed in a different device. (And even if it's possible to modify a genuine component to add backdoors, this still doesn't help, since they could just modify the one that came out of your MacBook too.)
In theory people will steal Apple devices, then when they learn that digital locks make them impossible to use they will gut them for parts and sell those. Serial locking would defeat that. In practice, yes, it pretty much just exists to make them millions off of forced overpriced in-house repairs.