A relative clause (Relativsatz) answers “which one?” or “who exactly?”: Der Mann, den ich kenne, ist nett. Without it you would need two short sentences: Der Mann ist nett. Ich kenne ihn. At B1 this is how you describe a person, a thing or a place in a single sentence: at the lost-property office, in a flat ad, in a job interview and in the speaking part of an exam.
The rule of this lesson in one line: the relative pronoun takes its gender and number from the word it refers to, and its case from the role it plays inside the clause. Everything else follows from that line. You will build three habits: find the reference word, decide its role, send the verb to the end. After that come Nominativ, Akkusativ, Dativ, Genitiv, prepositions and the special case of was.