Welcome to Reef2Reef! That is a great question! One thing to remember is that in a diverse aquarium, the corals in there are from different parts of the world. Each come in with different microbial communities, and they can incorporate and interact with each other's microbiome. If you then release these corals back into their native environments, you are potentially also releasing new pathogenic bacteria and new viruses onto reefs - acting as invasive species. This also does not include any potential ectoparasites that live on the corals, such as different parasitic copepods on Acropora.
There are many institutions that have ex-situ land-based aquaculture that are then transferred to the oceans, such as the Coral Restoration Foundation in Florida. In this case, they are only keeping and growing local species, so there are no concerns about invasive species. In terms of what this hobby can do for reefs, the best scenario for wild-reefs would be for this hobby to reduce the amount of coral we harvest and import from the wild. Hobbyists that want to make a difference should choose aquacultured corals over freshly harvested wild corals.