Russian President Vladimir Putin has agreed to hold talks with his Ukrainian counterpart Volodymyr Zelensky "if necessary", the Kremlin has confirmed.