Changing colors for a specific control or use case is not recommended. You can use AppStudio–>Settings–>Themes to setup the styles across your application.
Though this requirement can be achieved through Custom DX component, but this is not a best practice. Relying on background color alone will impact accessibility and does not meet WCAG requirements. You should not use color as the only way to convey “Yes” vs “No.”.