Mycorrhizal fungi take their name from myko= mushroom and rhizo=root. They grow on roots of trees and many other plants and help the plants to get nutrients such as nitrogen and phosphorus from the soil. So that the fungus can grow, the plants provide sugar water.
Plants produce sugar water with carbon dioxide and solar energy. Bacteria can also help plants to grow better by capturing nitrogen from the air and exchange it with sugar water.