After the forms оди́н/одна́/одно́, use the nominative singular (the basic dictionary form).
оди́н го́род
одна́ сестра́
одно́ окно́
After the forms два́/две́, три́, четы́ре, use the genitive singular.
два́ го́рода
три́ сестры́
два́ окна́
After the forms пя́ть, ше́сть, се́мь, … through два́дцать (as well as 25-30, 35-40, etc.), use the genitive plural.
пя́ть городо́в
се́мь сестёр
два́дцать о́кон
Careful! There’s a reason we emphasized forms. 12 – двена́дцать – doesn’t end in два, it ends in -дцать (!), so the rule about the genitive singular doesn’t apply here. We’ll use the genitive plural, just like other numbers from 5 to 20. That’s how we get the title of Ilf and Petrov’s classic satire, Двена́дцать сту́льев.
It has to do with words, not digits or Arabic numerals.
Yes, when you use the forms два́ or две́. But note that if you’re writing about two trips (о + prepositional case), or helping three friends (помога́ть + dative case), you’ll be changing the case form of the number itself, so the above rules won’t apply.
The Russian Grammar Library provides two video lessons and exercises on nouns after numbers, as well as the forms of nouns in the genitive singular and genitive plural.