Most upvoted comment
My Droid has a mind of its own! Know a fix?(r/Android)
Your digitizer is shot. It’s a hardware problem. You can buy a replacement from amazon for $30. If doing it yourself, its a long tedious process. Here’s video of how to take the phone apart