Two main reasons:
a) they take up resources on the server (not terribly much since the
connection is idle)
b) sometimes connections timeout themselves after periods of inactivity.
You want to either close them before that, or run some periodic "ping" SQL
to make sure they are still alive. Otherwise you'd get an error on the next
SQL you want to execute.