there are different types of server variables:
GET
POST
SESSON
COOKIES
The type of variable you are referring to in your example:
example.com/index.php?ID=3212
is a URL querystring or GET type of variable.
it is not possible to hide the query string from the address and still have it exist. instead, you would want to use one of the other variable types, a SESSION or form POST, to pass the variable to another page but not display it to the user through the address.