If the keyboard supports Windows Dynamic Lighting, open Settings > Personalization > Dynamic Lighting. From there, select the keyboard and change the lighting color to purple if that color option is available for the device.
If Windows is overriding the keyboard’s built-in lighting controls, go to Settings > Personalization > Dynamic Lighting and turn off the Dynamic Lighting settings. Then use the keyboard maker’s built-in shortcut or utility to set the color.
For simple keyboard backlights, Windows also supports brightness controls and automatic brightness behavior, but color control for RGB or per-key lighting is handled through Dynamic Lighting rather than the simple keyboard backlight feature.