Using an external SSD format like M.2 means the added monetary and power costs of 1) an external flash controller, 2) the mechanical components to interface with it, and 3) multiple PCIe lanes which can never be fully powered off.
Okay, it was part of the T2 chip before. And they were able to put replaceable SSDs into the Mac Pro. Those only contained the NAND chips and were proprietary, but still.
The problem I have with soldered SSDs is that flash memory has a limited lifespan in terms of writes. Once you're out of writes, then what? This is aggravated by the fact that M1 can't boot even from external media if the internal SSD isn't working.
(This was briefly not the case with that Big Sur SSD thrashing bug, but that's been fixed now)
Apple could and have put their SSDs in modules - that's how the T2 Mac Pro does it. They're still proprietary though, of course, due to the split design.
Interfaces are designed for specific characteristics like maximum capacitance and signal loss, and going beyond the design parameters means you need to change something. In this case, it would involve significantly increasing the power consumption of the interface.
so you do know the speed of signal in copper? ~20cm per 1ns. 5-7cm of extra track length to a slot would not hurt anything.
You cannot push a 512-bit wide memory bus like on the M1 Max through a connector and longer PCB traces without massively increasing the power consumption of the interface. Remember, those laptops have a memory bus equivalent to 8-channel traditional DDRx RAM. You'd need 8 SO-DIMM slots just to get the bandwidth, at a huge increase in power. LPDDR RAM isn't even available in modules for this reason; it's designed for low power, and using connectors goes against that design goal.