They can irritate zoas to the point of death, if there are too many. They will not prey/eat your zoas though.

If you have too many, I would recomend manual removal. Some people even actively seek spaghetti worms, if you want to post them up to get rid of.