When there is a collision between multiple objects and the final kinetic energy is different from the initial kinetic energy, it is said to be a inelastic collision. In these situations, the original kinetic energy is sometimes lost in the form of heat or sound, both of which are the results of the vibration of atoms at the point of collision. Though kinetic energy is not conserved in these collisions, momentum is still conserved and therefore the equations for momentum can be used to determine the motion of the various components of the collision.
Note: In contrast, a collision when the kinetic energy is conserved throughout the collision is called an elastic collision. Since collisions in the real world pretty much always result in some form of sound or heat being given off, almost all actual collisions are inelastic collisions, but some cases - such as two billiard balls colliding - are close enough to that they can be approximated as if they were actually elastic collisions.
Perfectly Inelastic Collision
While an inelastic collision occurs anytime that kinetic energy is lost during the collision, there is a maximum amount of kinetic energy that can be lost. This sort of collision, called a perfectly inelastic collision, the colliding objects actually end up "stuck" together. In this case, momentum is still used to figure out what has happened, but there are fewer objects after the collision than there were before the collision ... because multiple objects are now stuck together.
A classic example of this is shooting a bullet into a block of wood, called a ballistic pendulum. The bullet goes into the wood and stops. Kinetic energy is lost (mostly through the friction of the bullet heating the wood as it enters), and at the end there's one object instead of two. For two objects, this is the equation that would be used for a perfectly inelastic collision.
Equation for a Perfectly Inelastic Collision:
m1v1i + m2v2i = (m1 + m2)vf