"Qui" and "que" are used to join two related parts of sentences. In English you may use "that" or "which", or "who" or "whom" in the same way.
e.g. That’s the teacher who listens to his pupils
There’s the woman who lost her book
Here is a car which goes fast
That’s the pen that I lost
There’s the car that you would like to buy
Here is the rubber that I found
The subject of a verb is the thing or person doing the action of the verb.
e.g. She is washing the car – "she" is the subject
The object is the thing or person who is on the receiving end of the action of the verb.
e.g. She is washing the car – "car" is the object
In French, "qui" is used to join the subject to its verb, and "que" is used to join the object to its verb phrase.
e.g. C’est le prof qui écoute ses élèves (the teacher is doing the listening, therefore "qui" must be used to join the subject to the verb)
Voilà la femme qui a perdu son livre (the woman did the losing, therefore "qui" must be used to join the subject to the verb)
Voici une voiture qui roule vite (the car is doing the moving, so "qui" must be used to join subject and verb)
C’est le stylo que j’ai perdu (the pen is what I have lost, so "que" is used to join object and verb phrase)
Voilà la voiture que tu voudrais acheter (the car is the thing that you would like to buy, so "que" is used to join object to verb phrase)
Voici la gomme que j’ai trouvée (the rubber is the thing that I have found, so "que" is used to join object to verb phrase)