It seems that this is a recurring bug in the system. I have tried to find the solution online and tried various methods to fix the problem but to no avail. To be precise, every 10 minutes or so the black window appears and closes in a millisecond. It resembles something of a command prompt window. Sometimes it just appears and disappears other times it tends to minimize the full-screen application that is opened at that moment, usually games. I have tried to keep the task manager open to see what the actual process is being opened but never found anything suspicious. Then, I used screen recording software to grab the window and it finally displayed this:

I can see that the path leads somewhere in the "AppData" folder in my "Users" folder of C: drive but I can't tell what are the exact subfolders or the exact file location.
Things that I have tried so far without successful results:
-Running /scannow and the command that follows to try and identify corrupt system files issue
-Updating my graphics and Windows to the latest version
-Running Windows Defender, Malwarebytes, and SpyBot Search and Destroy but after scanning and fixing still the issue persists
-Disabling Hardware acceleration and "extensions working in the background" options in Microsoft Edge and Google Chrome (I don't have any other browsers installed)
-Running and scanning with Farbar Recovery Scan Tool
-Tried running Windows log event and seeing if some actions popup but couldn't identify the cause
-Many other solutions that I can't even think of at the moment
Another important note, since I play a lot of certain games where I press often the "F1" key, it happens that at times I press it at the exact moment when the window appears and the Edge browser opens the help page in a new tab on my second screen where edge is launched.... I suppose that this has to do something with Edge on some level because of that but I'll let you tell me if there is something that I didn't try yet...
Also if I need to provide some sort of log for you to identify the issue, please instruct me how to do so because this has been driving me mental for some time now... I don't have any suspicious software installed in the recent past as far as I can think of or see in my Installed programs.
Please advise and thank you