Technically speaking, the indwelling of the Holy Spirit did not occur in the OT, but an embuement occurred.
To better grasp indwelling, study the use of the Hebrew term “Shechanah” also referenced as Shekinah Glory, which is a manifestation of God’s physical presence.
It also is the source for the halo depicted in many 1st millennial Christian art pieces.
Did you mean imbuement? What's the difference between indwelling and imbuement?
Do not cast me away from Your presence, And do not take Your Holy Spirit from me. (Psalm 51:11)10 But they rebelled and grieved His Holy Spirit; So He turned Himself against them as an enemy, And He fought against them.
11 Then he remembered the days of old, Moses and his people, saying: "Where is He who brought them up out of the sea With the shepherd of His flock? Where is He who put His Holy Spirit within them,
12 Who led them by the right hand of Moses, With His glorious arm, Dividing the water before them To make for Himself an everlasting name, (Isa. 63)
Hope to get back to this today.