As the developing plant grows, the fungus grows with it. Once it's time for the flowers to form, teliospores are produced in place of the flowers and develop where the grain would be.
As the growing plant develops, the fungus accompanies its expansion. When the time arrives for the blossoms to appear, teliospores are produced instead and develop in the area where the grain would be present.