Hmm, I tested this functionality as a sanity check, and it is possible to do.
Test app (toggle state labels on and off with the button at the bottom)
https://codepen.io/noash/pen/MWWbWZy
Perhaps the MapServer you're using doesn't support dynamic layers? You need it to in order to make changes dynamically.
When you inspect the MapServer from REST, do you see:
Supports Dynamic Layers: true
?