It's not really possible this way. You should probably use stereotype instead:
@startuml
<style>
.foo {
state,stateBody {
BackGroundColor lightblue;
}
}
</style>
state MainState <<foo>> {
state SubA
}
@enduml
Hope this helps!
PS: Edited as the example was not correct