The city has to have the building to build that particular unit type for it to have free upkeep in that city. Also, there is a limit on the total number of units that can be upkeep free in a city. I think, it's 5 on maximum city size. Anything above 5 would be charged "at the regular rate". City automatically picks units that get the free-upkeep bonus: the bonus goes to the units with the highest upkeep (from the ones that can be built in the city).
Bookmarks