The conflict perspective is one of the main perspectives in sociology. It holds that various aspects of society are shaped by conflict between dominant and subordinate groups. This perspective would explain the disparity that you mention in this question by pointing to conflict between men and women.
Through the lens of the conflict perspective, men are a dominant group in American society and women are a subordinate group. This has been true for as long as the United States has existed. The ideas of male supremacy have been built into our ideas about proper sex roles. These ideas about sex roles shape the disparity you mention.
In general, K-12 teaching is less prestigious than college professorships. Teachers (particularly in the lower grades) are seen as babysitters as much as they are teachers. Their job is seen as similar to that of a stay-at-home parent and is, therefore, assigned to women.
The conflict perspective would say that this comes about because of conflict between men and women. Since men are dominant, they constantly try to put women in positions that are less powerful and less prestigious. When they can, they make this seem natural, as in the case of our society where we think that women are more nurturing and should therefore be in charge of teaching younger children.