Abraham's dealings with surrounding nation "recapitulate" the experiences of Israel in advance. Or perhaps we should say, they anticipate them.
Abraham saw his wife, Sara taken into captivity in Egypt (Genesis 12). But Pharaoh's house is plagued, and Abraham goes out with great spoils.
In chapter 14, Babylon came to take his nephew Lot captive and exile him; but he was rescued and restored.
In chapter 18, the filthy Canaanites are leading Lot and his family into corruption; they are judged, but part of the family falls to the judgment, and lasting scars remain behind.
In chapter 19, there is a tustle with the Philistines (via their king, Abimelech), who endanger the fulfilment of the promise. Abraham proves weak and unfaithful; and his treasure, the bearer of the covenant promise is taken away - but later is voluntarily returned by Philistines who are eager to avoid God's judgments. (Thus anticipating the capture and return of the ark - I admit I'm not quite so sure of my grip on this one, and suspect there is more).
This is emblematic of the dangers which Christians face in the journey to glory. They need to be redeemed out of slavery to sin. They need to avoid worldliness - which leads to being carried off in the judgments that will fall on the worlding. They need to avoid like the plague the filthiness of the people who don't know God and follow their own lives. And they need to... hmmm; those pesky Philistines. They need to maintain faithfulness at all times and trust in the sovereign God who delivers us from far greater challenges than we are capable of?
Christ redeems. Christ reigns from heaven and calls and empowers his people to live heavenly lives on earth, in anticipation of the arrival of heaven on earth (and not worldly lives that lead to us being washed away when the worldly are). He is holy and calls his people to be holy too; and his Spirit teaches us to be holy so that we do not share with the children of filthiness and children of wrath. He trusted fully in his Father, who delivered him even from the grave - and so must we trust in God through him.
The Bible's stories have far deeper connections, resonances and messages that we are intended to pick up, than we realise. I'm just scratching the surface in this quick jotting of a few passing thoughts. Most of us have grown up in very technocratic, image-obsessed, moment-focussed, story-and-imagery-impoverished settings that have deprived us of a lot of our understanding of the Scriptures' message.