Charging a 400+% markup for storage and RAM does not suddenly make a laptop professional. Sure, if there was a significant difference between screen size, chip, battery life, etc, you could argue the $999 one is a prosumer device and the $1799 laptop is a professional device. The only difference between a $999 laptop and a $1799 laptop is 768 GB of storage and 16 GB of RAM. I will even be generous and say that is a $700 difference because Apple tosses in two more GPU cores ($100) when you go over a certain amount of RAM. On Amazon, I can get a 1TB M.2 drive and 32 GB of DDR4 SODIMM RAM for $150 total. A premium from Apple on those components would be $300-$400. They are at $700-$800.
If you are buying professional work equipment, a difference of a few hundred dollars does not matter. Professionals in any field usually have equipment worth thousands or tens of thousands of dollars.
And if you're buying a computer as a consumer because it is a premium machine, well then you eat the price if you really want the machine, or you have to go for non-premium competitors.
You're comparing McDonalds to a nice steak in a good restaurant. The good restaurant will charge dearly for a bottle of water while McDonalds gives you free refills, and so on. The business models are different and the market segments are different.
Odd, every steakhouse I have been to gives me as much water as I'd like, free of charge.
I'm not comparing a hamburger from my local go-to to a steak from a steakhouse. I'm comparing the cost of the mash potatoes that comes with my hamburger ($5) and what they cost at a non-Apple steakhouse ($15). I don't go to the Apple steakhouse not because I find their steak unreasonably priced (it is a great value, actually), but because I refuse to pay $60 for mash potatoes, and if I don't get the mash potatoes, the steak has no value to me.
What I'm saying is that you're comparing apples to oranges.
A steak in a nice restaurant and its accessories will always be more expensive than a burger meal at McDonalds.
Apple has invested enormous effort into making high quality software. They offer the only operating system on the market which is any good at all. But their business model is selling hardware, so that's where they have to bake in all their costs. And their hardware is top notch as well. They could change their offerings to charge a high basic price on all their devices and then offer RAM and SSD upgrades for the low prices you are mentioning. But they choose instead to have a lower base price, knowing that the only people who need more RAM or storage (need, not want), are professionals who can pay for it.
It's the same in a nice restaurant. You're not paying for the ingredients, but everything around it including staff, the environment and so on. That's why a beer is so god damned expensive when you go out.