The Torah tells us (Genesis 4:17) that Kayin built a city and named it after his son, Chanoch. If Chanoch was only of the third generation of humans, how was the total human population at the time enough to populate a city?
Ramban on this verse says that in fact Kayin built the city for his son to live in. (The minimum size of a city, in halachic terminology, is pretty small - six houses are enough.) He also says that Kayin continued building this city for a long time (thus the ongoing form ויהי בנה instead of ויבן), so he may have started small (just a couple of houses, for his wife and for Chanoch, plus some outbuildings) and kept expanding it as his family grew.
In halachah, in fact, a city is really only considered such (for purposes of Purim, and of the special laws governing the sale of houses in walled cities) only if it was "first walled and then settled" (Megillah 3b and Erchin 33b) - much like in this case.