UFW and ping

Hello, I spend a hard time to let ufw allowing ping command. On our snap core, there’s no way to add configuration file in /etc/ufw/before.rules. I tried ufw allow icmp without success.

Is there’s a way to add a specific rule for ICMP?