i don't have a fish tank but i need this question about a cowfish answered please help

35% Off ! All WYSIWYG fish and corals
so i was recently at my local zoo and in one of the reef tanks i found a very social cowfish (maybe). i was just sitting by the glass watching a school of fish swim bye and every once and awhile the cowfish would swim over turn almost completely white, spread out its tail and flick it up and down and then swim away what the heck does this mean!?! i have looked all over the web and can't find a anything else except that cowfish changes color when their stressed and are about to release a toxin but the color returned to the fish once he was away from me. please help