Divorce or legal separation???

Someone told me that when you “ legally separate” from your spouse in the military that it does not go through any actual courts. It’s basically just an agreement through the military that this is how this will be split until things are resolved ? Is that true ? I’m also in the state where separation is not recognized so idk if that law applies I service members . So basically I’m asking if I go to legal (on base) and file for separation will it go through any courts or will it just stay within the military . I hope I’m making sense 😂