<!--- Verify first that your issue is not already reported on GitHub -->
<!--- Also test if the latest release and devel branch are affected too -->
<!--- Complete *all* sections as described, this form is processed automatically -->

##### SUMMARY

Two vmware modules uses `copy()` to duplicate an internal instance of a pyvmomi object. This to be able to modify the object during an iteration.

- https://github.com/ansible/ansible/blob/622a493ae03bd5e5cf517d336fc426e9d12208c7/lib/ansible/modules/cloud/vmware/vmware_guest.py#L788
- https://github.com/ansible/ansible/blob/622a493ae03bd5e5cf517d336fc426e9d12208c7/lib/ansible/modules/cloud/vmware/vmware_datastore_facts.py#L220

As explain here, https://github.com/ansible/ansible/pull/60196/files#r312643761 this is not the best approach and this may impact the performance.

##### ISSUE TYPE
- Bug Report

##### COMPONENT NAME

vmware

##### ANSIBLE VERSION
<!--- Paste verbatim output from "ansible --version" between quotes -->
```paste below
devel
```
""" Wrapper around get_all_objs to set datacenter context """
        objects = get_all_objs(content, types)
        if confine_to_datacenter:
            if hasattr(objects, 'items'):
                
                
                tmpobjs = objects.copy()
                for k, v in objects.items():
                    parent_dc = self.get_parent_datacenter(k)
                    if parent_dc.name != self.dc_name:
                        tmpobjs.pop(k, None)
                objects = tmpobjs
            else:
                
                objects = [x for x in objects if self.get_parent_datacenter(x).name == self.dc_name]
        return objects
    def get_network(self, network):
        if network not in self.networks:
            self.networks[network] = self.find_obj(self.content, [vim.Network], network)
        return self.networks[network]
    def get_cluster(self, cluster):
        if cluster not in self.clusters:
            self.clusters[cluster] = self.find_obj(self.content, [vim.ClusterComputeResource], cluster)
        return self.clusters[cluster]
    def get_esx_host(self, host):