Zillow Group Inc. reached an agreement to sell about 2,000 properties from the home-flipping business that it's winding down.