The same issue appeared in version 1.19.4, where the volume of sounds in custom resource packs does not decrease with distance. Instead, it stays constant and follows the player at the same volume during playback. However, this does not happen with sounds in the original Minecraft.
What I meant was that using playsound to play sounds, like minecraft:xxxxxx, works without any problems.
when using playsound to play sounds from resourcepacks, such as custom:bgm.01, the volume does not decrease with distance, even if it is more than 16 blocks away or further.