My chickens and ducks both got into the foam insulation around their boxes, thanks to my poor carpentry skills. And, they ate a lot of it, fast. It was the pink Owens Corning foamboard, not the white styrofoam. When the ducks did it, I was sure they would get sick or die or something, but it didn't seem to hurt them one bit. So, I was a little less freaked when the chickens did it.
But, I would never intentionally let them do it. I would think it could have the potential to cause bowel impaction or similar problems.
There must be other things you could give them to occupy their time. Mine seem to enjoy cabbage leaves -- what about giving them a whole head of cabbage to work on? Potatoes, sweet potatoes, apples, pears, zucchini all might work as well.