It sounds weird to me too, and would make more sense without the "the": "What purpose does teaching have?" But I suspect you might use it (in Norwegian, at least) when referring to a particular instance of teaching, like: "What purpose does the teaching (of this particular thing) have?"
The online dictionary at UiO uses mål to describe formål and vice versa. I think one can say mål = target and formål = intention. Sometimes they can be used interchangeably. Mål can have separate divisions/parts, you manage one and you go on to the next, delmål. There will be a main goal/target at the top hovedmål/endemål. Formål has just one form.
Hvilket mål har undervisningen? = what do you want your students to learn, what do you hope is the end-result, what will the students need this for (they need to know the alphabet before learning to read, my goal is to teach them the alphabet today). Hvilket formål har undervisningen? = why are you teaching this, why this method and not that, what is your intention behind teaching this (I hope they will be able to read a book on their own).