I have just done a complete reinstall of macOS big sur 11.6 and I cannot seem to get custom folder icons to work. They just show up with a generic file icon instead:
In the Finder on your Mac, customise folders with colours, symbols or emoji, and choose a picture or icon to replace the icon for a file or folder.
support.apple.com
Important bit.....After you paste, if you see a generic JPEG or PNG image instead of your own picture, make sure you choose Edit > Copy before pasting.
I had the same problem and found that you have to open the icon in preview before you copy (or something like that!) but got it working just fine eventually.
Good luck!