First, I would challenge your assumptions that professors are not involved in the coding part. Even if they are not directly involved in delivering the labs, many professors are in fact involved in designing the lab classes, including problems that are offered to students. Sometimes professors also include suggestions on how to deal with most common learning obstacles, how to respond to most common questions, and which hints to give at which situations. Professors also design assessment problems and the marking scheme, i.e. instruct TAs onhow to evaluate the codes submitted by students. To summarise, there is a lot of work behind the scenes, which is Professor's responsibility.
Designing the course requires a lot of high-level expertise and understanding of the subject. It takes certain mastery to structure the material and arrange it in a way which keeps students involved, interested, and appropriately challenged along the course. To design a course which runs smoothly, professors have to create a sequence of effective teaching events which spans several weeks / months and involves tens / hundreds of students. TAs usually are given precise instructions for each class and plan how to effectively discuss the given problem in a small(er) tutorial group, or how to answer questions of a single student. Although this work also requires some creativity, it's more scoped and therefore easier to plan and prepare to.