Single-family home sales declined in June, the first such dip in five months, and inventory hit a nearly seven-year high, new data show.