I wanted to ask if my teacher came today or not. What would be the correct way to ask that question?
Has teacher came?
Did teacher came?
First off, you are talking about a particular teacher. So you should use the determiner "my" or "the" in front of "teacher".
Secondly, you use the first form of a verb with the auxiliary verb "did". So you should use "come" instead of "came". The correct sentences should be as follows:
Has the/my teacher come?
Did the/my teacher come?
If you are still at school when you are asking the question you could say "Did the teacher come today?" but it would be better to say "Has the teacher come today?" because you are expecting your teacher to be in school if he has come.
If you are at home and your mother is asking you about the teacher your mother would say "Did the teacher come today?" because she is asking you about something that is past and, even if your teacher came, he might not still be at school.
As others have already pointed out the basic structural problems, I won't repeat that. Instead, I'll add that other forms might be more appropriate. Instead of using come, we can in this example substitute it for arrive. (The reason for doing so is that it preseves the intention of the sentence, while better highlighting the difference between the did and has question forms.)
Did the teacher come?
Did the teacher arrive [at all]?
The sense of this question is in the past: I came to school at 9am and left at 11am, and the teacher wasn't there during this time. I want to know if the teacher was present at all during the day.
Likewise, we can rephrase the second variant:
Has the teacher come?
Has the teacher arrived [yet]?
The sense of this question is in the present, and ongoing: I came to school at 9am and am still here, waiting for the teacher. Somebody else, who might have more information than me, is present. I will ask if he knows.
"Has the teacher come" simply means you are still expecting him or her. "Did the teacher come" implies you only want the information (school hours are probably over). Just as "she has been waiting or she has waited means she is still waiting while " she waited" implies she left having waited for a while.