1. Teacher of Spanish. = He or she teaches Spanish.
2. Mr. Smith is a SPANISH teacher. (He teaches Spanish.) [Stress -- say strongly -- the word "Spanish.']
3. Mr. Smith is a Spanish TEACHER. (He is a Spanish person. Maybe he teaches science.) [Stress "teacher."]