I also thought about this but then look at the iPad and iPhone Facetime cameras. They offer much better image quality than Macbook webcams. There are a few ways to offer "rear camera" quality on Macbooks, like having a little bump sticking out from the back. I don't think that's what people are asking for though. They just want a webcam that's as good as the webcam in their phone.
Also this doesn't answer the question of why USB webcams are so terrible. They have tons of room.
Those devices are significantly thicker that a MacBook display.
I could imagine a bump towards the front that would sink into the body when closed, but doing it in a way that looks and feels good also seems rather hard - but also harder to avoid should they want to implement things such as face id.
Fortunately this is the Internet. You can see those parts plenty of places - like ifixit for example. Yes, the front facing cameras on iPhones are thicker than what would fit in a current MacBook display.
Honestly though, I think the real reason webcams on laptops suck is that until recently 95% of people didn't use them 99% of the time.
That improvement in image quality requires Apple Cortex CPUs due to Apple’s implementation strategies for cameras. I expect Apple will update the cameras in future laptop models as Apple Silicon arrives fully across their product lines, likely using the same package from their phones.
Also this doesn't answer the question of why USB webcams are so terrible. They have tons of room.