An excellent move, removing the power of a potential bishop on the h1-a8 diagonal, preparing Bf2-g3 and securing the e4-square for the knight.
17... d8e8  18. h5f6  18... f8f6  19. f3e2 White is fighting for the advantage again. 19... e8g6 