That teacher sounds insane.
That being said: There is nothing wrong with telling people to know their rights, be wary of how they respond to police, and better yet, not respond at all beyond what you are legally required to provide. Everyone should watch videos like this one to understand why no matter how innocent you are, dont provide literally anything beyond what may be legally required. Watch any facebook or youtube video of somebody not providing police with answers/pleading the fifth and swarms of morons call them rude idiots or how "they should just cooperate."