Let’s say I decide I’ve had enough with this whole Federation business and that humanity would be better represented by a Starfleet that follows my particular ideology. Assuming I could get enough people for crew and support, why can’t I start my own Starfleet?
I could replicate ship parts until I have a couple vessels. Go to new worlds and present myself as the official first contact of humanity. I could fly to Vulcan or Bajor and tell them no actually my organization represents humanity.
What’s going to stop me?
Depends on the writer, but they handwave a lot of those problems by the fact that replicators need a lot of energy to work (voyager explicitly said they didn’t have the spare power and used hydroponics and trade to supplement), and a lot of critical components couldn’t be replicated (dilithium, and antimatter containment parts. Also the isolinear computer chips were non-replicatible). I think you’d also struggle with any weapons systems, which might include shields.
Essentially you could build the hull and most of the mechanical parts, but not the critical systems.