Solution 1:

In Terminal Services Configuration -> Connections

Right click on RDP-Tcp, choose properties and select Sessions tab.

You will then see the options for ending disconnected or idle sessions after x minutes, hours or days.

Solution 2:

Also configurable through group policy, if you don't feel like touching all your servers' settings individually.