There are two answers here.
The first answer is simply a matter of availability. At the time of the bombings there were very few nuclear weapons available, and if only plutonium weapons had been used in WWII it would have involved a delay of many days (perhaps longer) for the second one to be used (though, as always, it's tricky to evaluate counter-factuals), if only uranium weapons were used it would have been a much longer delay (months).
The underlying question is more interesting though, why did the Manhattan Project produce two different bomb designs in the first place? And that cuts to one of the core aspects of the project, it wasn't just one nuclear weapons program, it was several, all run in parallel and with tremendous expenditure of resources. If you're operating a "normal" procurement program (whether for nuclear weapons or anything else) you tend to go through a simple two phase process: step 1: do the R&D to figure out the feasibility of the thing and determine the best design; step 2: design and build the thing. And this is the way most nuclear weapons programs have occurred post-WWII.
But the Manhattan Project was more of a shotgun approach that amounted to essentially a wide diversity of separate programs operated in parallel. Three different fissile fuels were evaluated: plutonium (nominally Pu-239, but in practice a mixture of isotopes, bred from natural uranium), U-235 (separated from natural uranium), and U-233 (bred from thorium). Of these, plutonium and U-235 were found to be the most practical. For U-235, which required isotopic separation, several different methods were attempted for separation: gaseous centrifugation, gaseous diffusion, electromagnetic separation, and thermal (liquid) diffusion. Of these, centrifugation turned out to not be workable at the time, despite being initially the most promising (and, with technological advancements that would become true later). Graphite moderated uranium fueled reactors were used for manufacturing plutonium. Additionally, two designs were pursued for bombs: gun-assembly and implosion assembly. For a while it seemed that a plutonium gun-type bomb would be feasible (nicknamed the "thin man" design), but further data on pre-detonation likelihood with plutonium took that option off the table.
(Edit: also, there was a desire by some to scrap the little-boy bomb and rework the highly enriched uranium fuel into several implosion assembly weapons, but this was overriden in order to achieve the earliest possible use of nuclear weapons in the field possible. Meaning initially the full 4 way diversity of fuels x weapon designs was on the table even in 1945, though only two ended up being built and used.)
So, three fuels, five production methods, two bomb designs. Only a subset of which eventually proved workable. It's also worth noting that the uranium-enrichment processes ended up being used in series (one feeding into the other), and only then was there enough throughput to produce enough HEU to build a bomb by mid 1945.
It was this mad-dash, extreme effort shotgun approach which allowed the Manhattan Project to produce any weapons at all within the timeframe they did. Had they gone with a more conventional and conservative "pick the one best, most sensible design and run with it" approach they likely would have gone with U-235 via centrifugation enrichment in a gun-type assembly bomb. When they hit roadblocks with centrifuge based enrichment it would have meant a long delay while they evaluated alternatives and switched (maybe to gaseous diffusion, maybe calutrons). And even after switching it would have taken a very long time to get the HEU production throughput up high enough to build any bombs (especially with the gun-type weapons requiring such a huge amount of material), let alone at a production rate sufficient to provide an arsenal in a reasonable time frame.
It was that crazy scattershot, highly parallelized program which was able to produce two plutonium fueled implosion-type bombs by mid 1945 (one of which was required for testing) along with one uranium fueled gun-type bomb (which was so straightforward no testing was deemed necessary before first use).
After the war bomb designs in the US became a bit more standardized (and gun-type bombs were shelved), but they did make use of both plutonium and uranium, leaning heavily on the uranium enrichment technology that had been developed during the war (eventually focusing on gaseous diffusion). That technology also become useful with the advent of nuclear reactor technology, as most reactor designs used low enrichment uranium fuel.