Depending on who you talk to, the first use of a puck was in Kingston Harbour, Ontario, Canada in 1860. While it's unlikely that this first puck was made of rubber, it wasn't long after that that the rubber puck made its entrance into the game. Natural rubber is one of the most elastic substances known. A puck is compounded with other materials to give it strength and to make it less elastic, but pucks still have a rubbery nature. To take some of the bounce out of a puck for a game, it's frozen beforehand, and even kept frozen between periods.
Most substances behave similarly when heated or cooled.
To get an idea of how the temperature of the puck affects its motion, you can experiment at home if you have two spare pucks laying around. Put one in the freezer for a couple of hours while leaving the other one out to sit at room temperature. Find a flat area of cement where you can drop the two pucks. Drop the pucks from about waist-high and observe how they bounce after they hit the cement. Then try to drop them at the same time from a balcony, or simply throw them up in the air at approximately the same distance.