ジョンは先生に質問をした focuses on what John did, whereas 先生はジョンに質問をされた focuses on what happened to the teacher. As you know, the word marked with は is the topic of the sentence. These two sentences look equally natural to me, but they are not necessarily interchangeable. Which to use depends on the theme of the conversation.
In general, when "what was done" is more important than "who did it", people tend to use passive voice in Japanese (probably more often than you do so in English). In particular, when you are negatively affected by the action, the passive voice conveys such nuance well (known as "sufferer passive").
- 彼は僕を殴った。 He hit me.
- (彼に)殴られた。 I was hit (by him).
When you report this incident to someone, 殴られた is the default choice because you have been negatively affected by the punch. Saying the former would sound too indifferent.
When you cannot (or don't want to) mention who does the action, the passive voice is used both in English and Japanese:
This tower was built 200 years ago.
In this case, saying "They/Someone built this tower 200 years ago" is less natural even in casual English, isn't it?
The Japanese language tend to avoid taking inanimate things as subjects (see this). You can say "The news surprised me" (active) in English, but in Japanese, そのニュースは私を驚かせました is very literary and almost never happens in speech. A better way of putting it is そのニュースに私は驚かされました using the passive voice, which translates to "I was surprised at the news." (passive). But this is still a bit unnatural, and people usually say そのニュースに私は驚きました instead, using an intransitive verb 驚く that means "to be surprised". It's complicated, but note that in some cases only English speakers use passive voice. To take another example, "I'm worried" (passive) is usually "心配している" (active) in Japanese.
Lastly, this is a very big topic and it's hard to generalize when to use the passive voice. There is an article discussing the difference in the usage of passive voice between English and Japanese, but reading this may not help you understand the real usage much. Probably you need to read many real and long text to get used to the Japanese passive voice.