Phase transitions of a GUP-corrected Schwarzschild black hole within isothermal cavities