What is the difference in meaning between these sentences?
Ich spreche die Deutsche nicht.
Ich spreche nicht die Deutsche.
Ich bin nicht der Lehrer.
Ich bin der Lehrer nicht.
Well, the first two sentences are somehow wrong: it's either die deutsche Sprache or das Deutsch (but not die Deutsche, which means German woman). I would say (paradoxically)
For the second variant, with nicht, it sounds like something is missing.
As for the second sentence, first you must capitalize "lehrer". The first of the options sounds to my ears like something like in this example:
while the second option sounds strange. Then
is the right option.
Sometimes still the negation can also be put at the end of a sentence, as was done in the episode "Suppen-Kaspar" of Struwwelpeter:
Emphasis either on nicht
or on Lehrer
emphsis on ich