how to make substate that's a separate file?

I’d like to have a separate file with a state machine that could then be included in a different machine as a substate.
By doing so I want to be able to have some functionality encapsulated in a substate and be able to use it in various places without copy-pasting.

Has anyone had experience with that?

Is this something playables would handle? Research playables.