Thus they made a covenant at Beersheba: then Abimelech rose up, and Phichol the chief captain of his host, and they returned into the land of the Philistines.
So, they agreed at a place called Beersheba. After that, Abimelech and Phichol, his top soldier, went back to Philistine land.