Steps:
From your Shopify admin, go to Online Store -> Themes.
Find the theme that you want to edit, and then click Customize.
Click Theme settings -> General.
In the Favicon area, click Select image.
Click Save.
You can use a free favicon generator website to create a custom favicon, or you can create your own. To find a favicon generator, search the internet for free favicon generator.
The ideal size for a favicon is either 16x16 pixels or 32x32 pixels. If your favicon file is too large, then it will be reduced to 32x32 pixels when you upload it to Shopify