Yes, many edible flowers can be grown in containers and grow bags. Just be sure to choose a container that is large enough for the plant to mature and that has drainage holes.