NET Bible®
"So Abraham stayed in the land of the Philistines for quite some time."
— Genesis 21:34, NET Bible®
That is why he named that place Beer Sheba, because the two of them swore an oath there.
So they made a treaty at Beer Sheba. Then Abimelech and Phicol, the commander of his army, returned to the land of the Philistines.
Abraham planted a tamarisk tree in Beer Sheba. There he worshiped the LORD, the eternal God.
So Abraham stayed in the land of the Philistines for quite some time.