Simple answer - state’s rights. The Constitution does not state nor imply that FedGov has such a power so it becomes a choice for each individual state. The much abused Interstate Commerce clause/act might be used to apply pressure to CA into stopping this insanity but the court battles will take a long time.
Interestingly the hard left will find themselves in a quandary which will once again put their hipocrisy on display. They lust for unlimited FedGov power but since CA is doing something they want (ban ICE usage) they must support CA’s authority to invoke the ban.
California owns most of its roads, so only what it approves can run on them.