This is probably not an Ubuntu specific query. See this video, https://www.youtube.com/watch?v=VFL3Pr5B_N0
You’ll want to look about 8 1/2 minutes in to where he comes up with the answer, but this is good that the video also shows off how to come up with the answer. I prefer the point and click, move/delete the file/check the box method myself.
I usually do things like this by clicking on the taskbar tray icon and finding the “Notifications” and clicking the “Do not disturb” checkbox. It will look like this:
https://github.com/telegramdesktop/tdesktop/issues/7597
Mark for later use with ubuntu.