This means the “domain” of a device, once it comes in as a switch, stays a switch, ie switch.christmas_tree can’t be turned into light.christmas_tree.
See this post and thread, there is a way to make a new “light” entity from a switch.
For zwave, the zwavejs integration will bring the device in with the domain switch or light automatically as defined in the code, without giving the user really an option to change it. A dimmer is assumed to only dim lights, so it will be a light. On/off will generally be a switch. Lights and switches are different integrations, that have different options and behaviors.
Another option is to use zwavejs2mqtt, and then with mqtt you can write your own template to define the device’s domain however you want.