Avast detected the newly created empty application as a virus

My Android apps have been showing as viruses by Avast (and its partners) for a long time. Unfortunately, this issue had to be resolved.

I started investigating to find out which library was causing this.
I create an empty app in Android Studio, don’t add anything, and run the app. Avast detect it as a virus, too.
When running the application in “release” mode, it does not see it as a virus. In debug mode, it detects like a virus.