Because 1) teacher it is 3th person sing. yu -. U- it is 2th person sing. 2) Why not yumo ? I think can be also yupo. :)
Why do you think it should be uko?
-ko -- indefinite location.
-po -- definite location.
-mo -- inside/enclosed location.
Mwalimu is an M/Wa noun and takes the prefix a- in singular. When used with locative suffixes it behaves irregularly, becoming yu-.
I think you can use -ko and -po with ndani. I've definitely seen -po with it. Ndani makes it clear that we're talking about interiority.
I think it's one of those things that in practice Swahili speakers mix and match. Need to look into it further.
Can "Mwalimu yumo ndani," be translated as "The teacher is there inside," (using locative "there")?