Friction is actually caused by the elemental force of electro-magnetism between two objects.
Increasing the distance between the two magnets will cause a decrease in the force of attraction between two magnets.