I agree with Sue. The mushroom spores are in the potting mix. When the potting mix is kept constantly moist, then the mushrooms will pop up seemingly out of nowhere. Beneath the surface, you will probably find a thin white root system that may produce other mushrooms.
They are not a problem to your plant or to you unless you decide to eat it - toddlers beware!
Remove the surface soil and any roots that you find. Keep the potting mix drier in the future. Use a sterile, soilless potting mix in the future.