I completely agree with you that cooking should be taught in schools, but you seem to be convinced that making that specific class mandatory will solve all the problems of obesity. Myself, and others on this thread, have tried to point out the most glaring issue that the group most disproportionately affected by obesity simply does not always have access to healthier options. That's not even mentioning the mental health issues and social pressures that perpetuate obesity. None of which have anything to do with a person's knowledge or ability to cook.
As for the cost of implementing a cooking class, is not nearly as simple as getting a couple microwaves and a hot plate. There needs to be teachers trained in the coursework, equipment and facilities that needs to be purchased and maintained, safety protocols need to be created and implemented, a regulatory board is needed to inspect and maintain the safety and cleanliness, considerations for the various dietary or health concerns of each individual student that attends, etc. If a cooking class gets out on the budget and schedule, what other classes get cut to make room? Are those classes not already providing valuable life skills and/or a creative outlet for developing students.
Also, coming from someone that is a low socioeconomic peasant himself, tax increases always affect the poor.