Picture the large microwaves as a slinky, bouncing around in your microwave oven: the slinky isn’t about to fit through the little holes in the door.
Besides preventing the microwaves from reaching and heating up the food it conceals, aluminum foil tends to give off sparks that might start a fire.