The first verb of a verb phrase functioning as predicate verb does not necessarily agree with the head of the closest noun phrase, but with the head of the noun phrase functioning as subject in the clause in which the verb phrase in question functions as predicate verb:
(1) I know that [my mother, who has four siblings,] loves me.
(2) We need to understand that [native speakers of English] get subject-verb agreement right more or less automatically.
This rule sounds rather complicated, but it is not. The rule in itself is an example of what it might look like when we practice what we preach, in the sense that we make our sentences as clear, explicit, and unambiguous as possible. This means that anyone who knows the meaning of the words used in rule 11 also knows the exact meaning of it.
As the examples above show, there can be noun phrases between the predicate verb and the head of the noun phrase functioning as subject. In the first sentence (1), the noun phrase subject contains the relative clause
(3) who has four siblings
The last constituent of the relative clause is the noun phrase four siblings. This noun phrase is obviously plural, but since the verb agrees with the head of the noun phrase functioning as subject, it does not agree with the plural siblings, but instead with the singular mother.
The second example (2) illustrates the same fact. The only difference is that the head of the subject noun phrase is now plural (people), while the head of the NP closest to the predicate verb, i.e. the complement in the prepositional phrase functioning as postmodifier to the head people, is singular (English).
Moreover, it is important to understand that one and the same sentence may consist of more than one clause. If there is more than one clause in a sentence, there will be more than one predicate verb. Each predicate verb must agree with the subject of the clause to which it belongs, if there is a subject in the clause.
Please note that a non-finite clause need not contain a subject. If we have a look at our first example sentence above, we may conclude that it consists of three clauses, since it contains three predicate verbs, namely know, has, and loves.
These three verbs happen to be finite, so the clauses in which these verb phrases function as predicate verbs must also be finite. This means that there must also be subjects with which the predicate verbs must agree. The predicate verb know agrees with the subject I, the predicate verb has agrees with the subject who (which is coreferential with my mother, and thus third person singular) and the predicate verb loves agrees with the subject my mother, who has four siblings, which is third person singular.
If we want to understand all this, we need to know about clause elements, clauses, and phrases (and their internal structure). If you feel like reading up on this, please follow the links below.