Because of space constraints and power constraints. It isn't only the space for the memory that you need. You also need space on the die for the memory controller, caches and the memory channels.
If you look at annotated die shots of these CPUs you can see that the memory controllers use significant space on the die. So if you wanted to add more memory you needed to remove something else on the chip. Also you might need to change the cache hierarchy and the layout of the chip.
Like everything else in chip design this is a trade off. And the chip designers make different trade offs for server CPUs that can support up to multiple terabytes of RAM. If there were a big enough demand for a mobile chip with more RAM they would probably make one.
The two biggest reasons are laptops have only 8 or 16 GB memory because most people don't need any more than that and the people that need more are willing to pay the markup.
No one is asking for terabytes of RAM in a laptop. I have two 16GB SODIMMs installed right now on a consumer laptop with a consumer processor that I'm typing this on.
So it's hard to chock this up to anything but nonsense.
I might have misunderstood the OP. High end models are more expensive because the people that buy them are either businesses or enthusiasts. So they either have a monetary gain from the higher performance or they just want the best thing. SO both of them will pay a reasonable markup.
Another reason is that the high-end laptops are a low volume product so this increases the cost of handling them. So naturally you would have consider this in the price.
If you look at annotated die shots of these CPUs you can see that the memory controllers use significant space on the die. So if you wanted to add more memory you needed to remove something else on the chip. Also you might need to change the cache hierarchy and the layout of the chip.
Like everything else in chip design this is a trade off. And the chip designers make different trade offs for server CPUs that can support up to multiple terabytes of RAM. If there were a big enough demand for a mobile chip with more RAM they would probably make one.
[1] die shots: https://twitter.com/highyieldYT/status/1719379808516280716
Edit: I might have misunderstood the OP.
The two biggest reasons are laptops have only 8 or 16 GB memory because most people don't need any more than that and the people that need more are willing to pay the markup.