我是老师 and 我当老师 have the same meaning
while, 是 means 'am' or 'is' ,
当 means a state that you can easily change it. just like 'act as'
for example, I am Tom.we can say 我是Tom,but not 我当Tom
you can add occupation after 当,when we say I am a teacher. we can say 我是老师 or 我当老师.
or you can use it to explain assumption, let's play a game,you are student and I am teacher. 我们玩游戏,你当学生,我当老师。
当 also means 'when'. for example, when I was seven.当我七岁的时候