This is an example of "inversion". In inversion, the normal order of verbs and nouns are switched. You HAVE TO use inversion when you begin a sentence with a "not only" structure or an "only + preposition" structure.
Not only *is Bob* smart, but also kind= Bob is not only smart, but also kind.
WRONG: not only Bob is smart, but also kind.
Only by fighting *can we* win= we can only win by fighting.
WRONG: Only by fighting we can win.
These inverted structures feel literary and poetic.
When you use "preposition+which" or "preposition + whom", inversion is OPTIONAL, and makes the sentence feel VERY formal. If you separate the preposition, you CANNOT use inversion.
OK, formal: This is the head on which the crown rests.
OK, VERY formal: This is the head on which rests the crown.
OK, casual: This is the head which/that the crown rests on.
WRONG: This is the head which rests the crown on.