Closet light with FS20z no light switch

I have a closet light no switch to turn the light on and off just a White and a black wire can I used FS20Z-1 to turn the light on and off ?

yes,

but for your application I would consider a local “motion-sensing, screw-in adapter” or “Motion Sensing Light Socket” which always work without depending on the cloud, ST or your wiring.

caveat LED bulbs might not be perfect in either case.