I don't think you get how specialised these facilities are. They can't convert from one process to another, for the same reason they can't just build a new one on the new process. The physical building is not even slightly the bottleneck. If they can afford a new process they can afford a new building for it.
There's a story where a fab company tried to open a fab in America but the chips kept coming out broken, and they tried everything and the only thing that worked was disassembling the whole factory and rebuilding it in the exact floor layout of their Taiwanese one.
Sometimes they do salvage one or more machines as both processes use the same one. But that had better be worth shutting down the old process, financially.
This production is constrained by the machines in the facility. The ddr5 production line does not magically produce more silicon by staffing it with more workers.
A high-end chip fabrication line is a very highly-tuned system. It's not a case of just buying the right machines and slapping them together, even doing a copy and paste does not guarantee the right results. You need to spend a lot of time adjusting the process variables and troubleshooting issues to bring things under control, and then keep monitoring them to maintain that control because things will drift over time or further issues will occur. You also need to bring a whole new set of people up to speed with how the fab works, and they also need to learn the quirks of that specific one as they go. These fabs are already optimized for near 100% utilization of the machinery in them, so more people doesn't mean more capacity.
you can just sell the production line and re-purpose human workers for ddr5?
There's a story where a fab company tried to open a fab in America but the chips kept coming out broken, and they tried everything and the only thing that worked was disassembling the whole factory and rebuilding it in the exact floor layout of their Taiwanese one.
Sometimes they do salvage one or more machines as both processes use the same one. But that had better be worth shutting down the old process, financially.