At is also used for complete addresses, for example:
"I live at 22 Orchard Road, London, England."
On is also used for street names, for example: "I live on Orchard Road"
In is also used for geographical areas such as cities and countries, for example: "I live in London" or "I live in England".
So why do we live "on a street" but "in a city"? And how can you know for sure when to use in, on, or at? It depends on the perspective of the speaker, and what is considered acceptable in English. These are questions that all English learners encounter and they cannot be completely answered through rote memorization or lists of rules. As your exposure to English grows you will gain enough experience to be able to decide for yourself which is correct. Simply keep trying to understand, and eventually you will.