This gets a bit detailed — which is where the fun is! — but in short it goes like this. We have two systems to measure time: our everyday one which is based on the rotation of the Earth, and a fancy-schmancy scientific and precise one based on vibrations of atoms. The two systems aren’t quite in synch, though, since the Earth counts a day as a tiny bit longer than the atomic clocks say it is. So every now and again, to get them back together, we add a leap second on to the atomic clocks. That holds them back for one second, and then things are lined up once again.
This has to be done every two or three years, so why not just adjust the length of a day or year or something? The detailed explanation is at Bad Astronomy. Link