A canonical tag tells Google's crawlers what the primary URL of a page is. This allows the search engine to know which page should be indexed. A canonical tag is also called a canonical URL.
A canonical tag is used to prevent duplicate content. Sometimes multiple pages contain similar content, for example when there are different URLs for different devices or when another website has copied your web text. When you add a canonical tag to the original or main page, this page will be indexed and shown (higher) in Google's search results.
So the primary page contains a canonical tag pointing to the primary page itself, while the pages with similar content contain a canonical tag pointing to the primary page.