Pro-Russia rebels in Ukraine agree to open a humanitarian corridor for surrounded Ukrainian troops to retreat, Russian President's office says.