Remember the little word im? It’s used with locations which are masculine or neuter.
It’s the same with zum—it only goes with masculine and neuter nouns!