It can be sign of an upset in the digestive system can be because of not enough fibre in the diet, too much fresh food, dehydration etc, being on antibiotics (they can kill the good gut bacteria as well as the bad illness causing bacteria)
Keeping off fresh veg allows the system to rebalance with plenty of fibre (hay). You can also give a probiotic to help. They need large quantities of fibre (hay) going through their system all the times to keep things balanced. If the balance gets knocked out, then abnormal poops are the result. Keep them off veg for a few days to see if they go back to normal. If they do, then still stay off fresh veg for a further 24 hours. When you reintroduce veg, do so slowly, one small amount at a time. It can be best to start with herbs (coriander a safe daily herb).
If they don’t go back to normal after a few days without veg, then you will need to go the vet