not a teacher
I should add that I agree with Raymott. Although I made an assumption as to your meaning, that was a mistake in the sense that your sentence is still ambiguous.
As Raymott says, Tom could be asking about the place Tim left to go to Pakistan, or the place he lived in while in Pakistan.
In your very first post, without more context, Tim would have to ask Tom to clarify his question.
For example:
Tom: Where were you living at that time?
Tim: Do you mean in India, or when I got to Pakistan?