Languages are either inflected, meaning endings are added to words to specify their relationship, or uninflected, as in English, where the relationship is specified by the position in the sentence. We find speaking an inflected languages (such as French) especially difficult. We have to first develop an almost instinctive knowledge of grammar so we can apply the endings on the fly. The natives do not need to know the grammar. By growing up with the language, one way just sounds right, and anything else does not.
We also go by what sounds right. We run into trouble when writing where we have no sound to guide us, except in our imagination. In our English grammar of position, a modifier modifies the closest thing to it. Sometimes we garble the order and the logical modifier gets separated from the modifiee. Then what? Do we believe the logic or the grammar?
My favorite example of a misplaced modifier was a joke in the old movie, The Thin Man.
Nora Charles (Myrna Loy) walks into the room holding a newspaper. She tells Nick Charles (William Powell), lying in a hospital bed, “They say you got shot in the tabloids!”
Nick replies, “They’re lying! The bullet didn’t come anywhere near my tabloids.”
(The movie was released in 1934, just months before enforcement of the Hays Code began.)
“In the tabloids” should logically modify “say,” but it is too far away. The phrase is closer to “shot” and grammar tells us that’s what it modifies. All it took was for Nick to change the definition of “tabloids,” and you have the joke. (Actually, Nora’s line sounds stilted, but she said it better that it reads.)
Nora should have said, “They say in the tabloids you were shot,” and then there would be no confusion, but also no joke.