It's possible a glitching sd card can cause issues. If your using one remove it and then see what happens.
Some generic troubleshooting tips are.....
1. Clear your phone's System Cache Files by turning your phone Off and then from a set series of button presses go into the phone's System Files and clear the cache. No information is lost this way. You may need to insert your headphones or hook upto a computer with your data cable to get to this menu on the phone.
2. Put the phone in Safe Mode which disables your downloaded app's but let's your stock app's keep working. If the issues stop then this highlights a downloaded app as the possible issue. Come out of Safe Mode and start deleting your most recent downloaded app's one at a time until it stops. https://www.samsung.com/uk/support/mobile-devices/how-to-start-my-galaxy-device-in-safe-mode/
3. Back up and remove any relevant sd card and factory reset.
Current Phone ~
Samsung Note 20 Ultra 5G SM-N9860_256Gb SnapDragon 865+
Samsung One Ui 3.1/ Android 11.