Recently my iPhone 5S has become frozen as there was no or very little memory to save even a picture, I thought it was a software issue and later when I tried to hard reset it by pressing the wake & home button the red screen appeared. Later I restored the iPhone with iTunes on a Windows PC. Everything went normal and restoration was successful with no issues, but later the touch screen became buggy. Especially the keypad freezes often and also every time the touchscreen freezes I supposed to lock and wake the phone again and again to make the touchscreen responsive.
There is less chance it would have a hardware damage. Because I am using a very rugged hard case cover as well the iPhone is wrapped up with Touch Screen Protector, hardening the glass. The phone is out of warranty as well. I never dropped even accidentally as well I always keep my phones in my pocket or either on my desk.
I even have tested the touch screen by removing the Hard Glass screen protector also, still the problem persists even after cleaning the phone properly. Moreover my phone has enough space now after the hard reset and restoration, more than 9 gigs to do IO read/write.