Use a proper pronoun
The man WHO was wearing a black hat is a spy!
yes, the man is the subject
The men WHO were arrested by the police had broken into Fogg's house!
yes, the men are the subject
I saw a man THAT was stealing a bike yesterday
No, that refers to the man who is the object not to I that is the subject
The dog WHICH was chasing the ball is a golden retriever.
Yes, the dog is the subject
The boy played with a ball WHICH was mine
No, which refers to the object " ball" not to the subject " the boy"