Yes but poor storage discipline and basic boiler maintenance is a slippery slope.
Drain boilers fully between use, open valves , remove whistles.
Store in a lidded plastic box and put silica gel packs in or a tied up sockfull of uncooked rice in the box. This is essential practice when storing in lofts, cellars, outbuildings etc.
Engines kept in doors usually just need draining drying and left open to vent.