First mentioned in Order of the Phoenix, Occlumency is the art of clearing your mind and blocking anyone from gaining entrance into it, making it easier to hide the truth or one's intentions from an enemy.
Snape must teach Harry this skill in order to cut off his mental link to Voldemort. This proved extremely difficult considering the advanced level of concentration and control needed to be even an adequate Occlumens, accompanied by Harry's lack of willingness.
Severus Snape, Dumbledore, and Voldemort are all accomplished Occlumens, which was necessary for their survival. Draco Malfoy was taught Occlumency by Bellatrix Lestrange, and was able to block Snape's counter-attack of Legilimency and to keep the secret of his plot of Dumbledore's death.
Occlumency involves not only clearing one's mind, but separating oneself from one's emotions in order to prevent a Legilimens from probing one's mind.