The Federation did develop cloaking technology on its own.
In 2358, Starfleet Intelligence equipped the USS Pegasus with a device capable of rendering the ship both invisible and intangible. The only problem is that the Federation was forbidden from developing or using cloaking technology in its spacecraft under the Treaty of Algeron, signed between the United Federation of Planets and the Romulan Star Empire in 2311. This was all documented in the TNG episode, "The Pegasus".
Here's what the Star Trek Encyclopedia has to say about the Treaty of Algeron and the phasing cloak:
Treaty of Algeron. Peace accord established between the United Federation of Planets and the Romulan Star Empire following the Tomed Incident of 2311. The Treaty of Algeron reaffirmed the Romulan Neutral Zone, violation of which by either side without adequate notification would be considered an act of war. ("The Defector" [TNG]). The Treaty of Algeron also forbids the Federation from developing or using cloaking device technology in its spacecraft. ("The Pegasus" [TNG]).
phasing cloak. Invisibility-screen generator that was designed not only to disguise a starship from visual and sensor detection, but also to alter the atomic structure of the ship, so that ship could pass through normal matter. The strategic advantages of the device would have been numerous, and the Federation covertly worked on its development, in violation of the Treaty of Algeron. The cloak eventually proved itself in practical use, but the Federation was forbidden from using it by the terms of the treaty. ("The Pegasus" [TNG])
Starfleet also used cloaked self-replicating mines to block passage through the Bajoran wormhole in the DS9 episode, "Call to Arms".
Additionally, in Star Trek: Insurrection, a cloaked holoship was deployed to the Ba'ku planet on the orders of the Federation Council.
Moreover, seemingly cloaked isolation suits were worn by Starfleet observers on the planet's surface.
The use of cloaking technology in these suits wasn't specified within the film itself, but it was specified in the script.
Outside, several other cloaked figures move among the unknowing Ba'ku...
But as Sojef speaks, Artim turns to see the floating head of Data DECLOAKING in mid-air barely a yard away as he removes his helmet... the boy yells... jumps back, falling as Data makes eye contact with him. The Ba'ku scatter... Sojef pulls the boy away to safety...
We notice a slashing burn wound on Data's neck as he fights off an invisible force again... we hear a ripping crunch and a green force field sputters briefly -- a Son'a man in a torn isolation suit partially DECLOAKS as he is slammed to the ground, unconscious. Data rips off the rest of his suit revealing himself, picks up a weapon from the unconscious Son'a, aims it at the rock face...
All the invisible men in suits DECLOAK in the village.