Here are the two big things you have to know about pronouns. A pronoun refers to a noun in the sentence. A pronoun can either take the Subject Case or the Object Case.
Mary lent her book to Tom. She told him to return it to her soon.
In these two sentences we have the nouns, Mary and Tom. Instead of repeating Mary and Tom, we use the pronouns she and he (she for Mary and he for Tom, of course).
Notice that the sentence does not use he but him. If we are talking about the subject of the sentence and we are referring to Tom, then we want to use he. If Tom is the object of the sentence, then we want to substitute him. Therefore he is the subject case and him is the object case.
For Mary, she is the subject pronoun and her is the object pronoun. Notice how in the second sentence, the recipient of the action is Mary, which means the pronoun must be in the object case. So we use her.
I gave Tom an apple. Tom handed it back to me.
I is the first person subject pronoun. Me is the first person object pronoun. It refers to the apple and is a third-person singular pronoun.
We gave them a call. They did not answer but called us back later.
We is the first-person plural subject pronoun (I know, that’s a mouthful). And us is the first-person plural object pronoun. They is the third-person plural subject pronoun and them is the third person.
Pronouns may seem basic but you got to know the fundamentals before you try the harder stuff.