Glycerin is typically used for textural purposes or as a sugar substitute when making candies or icing. It's particularly good for keeping fondant malleable. Glycerin is also sometimes added to salad dressings as an emulsifying agent.
When cooking with glycerin, it's important to buy food-grade glycerin. Glycerin also comes in flake form. Since glycerin is a natural emulsifier, it doesn't dissolve in water. When cooking with glycerin flakes in recipes that call for them to be put in water, it's important to also use oil and make a 2 percent solution. Once the glycerin flakes dissolve in oil, they can be mixed with water.