No, because "gerekiyor" doesn't quite work like "need" in English. It's better translated as something like "is needed for..." notice that, in the example, "bana" is used, not "ben." So it actually literally means "a good teacher is needed for me," and NOT "I need a good teacher." Hopefully that makes sense
If you say "It is necessary", you already have a subject: "it" ... so you can't just throw "a good teacher" into the sentence. If you want "a good teacher" to be the subject of the sentence, you have to remove "it" and place "a good teacher" there as you did in your other comment.
We do sometimes have "it" as a placeholder for an infinitive phrase with "to" (1) or a clause with "that" (2)
(1) It is necessary to dance. (= Dancing is necessary.) (2) It is necessary that the students have a good teacher. (= That the students have a good teacher is necessary. ... this sentence is correct but very, very unnatural.)