There is a very easy reason they don't do that, support.
Apple has learned from the Macbook and iPhone that the less difference you have in the hardware, the easier it is to deal with problems.
The idea of apple is that it just works. OS updates only need to be tested on a small subset of devices. There's no need to worry about the myriad of RAM suppliers and SSD manufacturers. You only need to deal with a small subset of CPUs and GPUs and there's no general purpose PCIe slots anywhere. The only thing with unknown hardware are the USB and Thunderbolt ports, and they have very specific protocols that make them much easier to test with.
The cost of supporting the desktop line so that from the casual user it's as easy as the laptop and mobile lines is far too high to be worth it. Yes expandable desktops would still be profitable, but any bugs or glitches that are out of their control could be a public relations nightmare for them.
It's annoying, but I get it. The computers need to be just good enough that they work nicely and for 99% of Mac users they do.