The primary market is where new private companies wanted to issue shares for the public and hence go for an Initial public offering. In simple terms, Initial public offering comes under the primary market where shares of a company are issued to the public for the first time.
The secondary market is the place where the shares of public listed companies are traded between different investors. In simple terms stock exchanges where millions of trades of the share of different companies happen daily between different investors comes under the secondary market.