Upgrade of the MAGNEX spectrometer toward the high-intensity phase of NUMEN