Sometimes a leaf falls off the plant. The soil uses this as nutrition. This is a normal process, only sometimes small flies form. The flies lay eggs again, etc. Fortunately, in garden centers you can find "nematodes", which combat the pests. This is available in powder form and you pour it over the soil with water.