A Docker registry stores Docker-based container images. After building a Docker-based container image, you can push it to a public container registry such as a Docker Hub, to a private registry on cloud, or on-premise.
You also have the facility to search for existing public images, and pull them from the registry to your own host.
Docker Hub is a public Docker registry, which serves a huge collection (probably the largest) of existing images, and allows you to push your own. In addition to that, Docker also provides Docker Trusted Registry, which can be installed on-premises, or on a cloud. It allows you to store your Docker images, privately and securely, behind your firewall. There are also cloud-based private registry providers which you can use within your cloud environment, such as AWS EC2 registry and Azure container registry.