All of what Purrbox said is true and accurate. They aren't plants, rahter they are a form of algae. They will float around the tank on their own if you have enough light. You can actually see the balls pearling with oxygen if conditions are correct.
They are useful in shrimp tanks but you should NOT keep them in tanks that house goldfish as they will consume them. If they are $5 each I'd think about getting some depending on their size. That's a pretty good deal. Also, you will want to rinse them out every 2-3 weeks. Simple hold them in your hand and squeeze them as you would a stress ball. Don't worry, you won't break them, that's how you rid them of wastes and debris. Use clean water to clean them and squeeze them while they are in a solution of this clean water.