Why does my iPhone keep switching from Silent mode to ringer?

When I set my phone down it keeps vibrating. Not plugged in or anything. It goes from silent mode to ringer every 5 seconds. What can I do to fix it? It's so annoying

Did you get it wet earlier my phone would do that and worse when it was wet

Either make sure it is on one or the other, plug in to iTunes and restore (make sure to back up before doing this), the classic turn on and off, and lastly if none of these work then set up a genius appointment online