You can go to any melee weapon holdable blueprint and in the class defaults search for Melee Surface Sounds. To Add a new surface sound for that specific melee weapon follow the video below. This is the sound that will be played when the melee weapon hits a material with the set surface type.
In the example above the melee weapon will now play the build sound when it hits a surface that is using the PM_Body physics material. Using this system you can set a specific sound for every surface type.
To learn more about physics materials and surface types you can find the Epic documentation linked below. But you can find and create new surface types in the Project Settings just search for Surface. Once you have added a new surface type you can set that in a physics material.