When treats are used properly in dog training they are a reinforcer. This type of dog training uses operant conditioning to teach (or perhaps un-teach) a dog behaviors. (Think of the word operant in terms of operating on the environment and being conditioned by the result.)
Treats are used most often as a positive reinforcer: something that is presented when a dog performs a behavior that we want to see more frequently. The addition (that’s where positive comes from) of the food reinforces the behavior.
The science behind this influences everything from which park benches pigeons return to in city parks to whether or not you are going to order takeout from the same restaurant you did last Friday night. It’s not up for debate. It’s a natural phenomena.
The reinforcer doesn’t have to be a treat. It just has to be, well… reinforcing. Some dogs will work for a game of fetch while others will watch you throw the ball and just stand there. Some dogs will work for a game of tug, others a scratch behind the ears, and still others an opportunity to chew on an old shoe.
Trainers use food for a very simple reasons: most dogs will work for treats. Some may require really interesting food, and others may even need to be fed a meal during training (I.E. not fed before class), but when it comes to reinforcers food is the lowest common denominator and works very well in a room with 6 or 7 other dogs.
A good trainer will introduce the idea of using other reinforcers early in your training and get the treat out of your hands very quickly, but there’s nothing wrong with using food in a classroom to introduce new behaviors. As a matter or fact, there’s some pretty basic science behind it.