Oscillatory exchange coupling in the two-dimensional limit