A repository is a container or memory storage that holds the snapshots inside it. A single repository can store one or more snapshots. Snapshot is nothing; it is a data backup of Elasticsearch taken by the user to release the memory and secure the data.
You can create any number of repositories in Elasticsearch, which can hold several snapshots inside them. The repository provides a location and memory to store snapshots.