Yeast infections are caused by natural yeast inside your vagina growing too fast. Anything scented, flavored or sweetened can cause a yeast infection. So bubble bath, sprays, douches, scented soap, scented menstrual products, playing with fruit, food or candy down there, not washing your hands or toys when masturbating, taking antibiotics and many many other things.
You can treat it with over the counter medicines found at your local pharmacy or supermarket.