There is no contradiction. The Bible speaks of the indwelling of the Trinity, and of the Trinity and dealings with humans, with nuances that we must recognize.
Joh 14:17 even the Spirit of truth, whom the world cannot receive, because it neither sees him nor knows him. You know him, for he dwells with you and will be in you. (ESV)
Joh 14:23 Jesus answered him, “If anyone loves me, he will keep my word, and my Father will love him, and we will come to him and make our home with him. (ESV)
For example, while it was the Son, the second "person" of the Trinity that took on human flesh, yet, the Father was in him and he in the Father, while he was also filled with the Holy Spirit (Luk 4:1). Similarly, while the Holy Spirit is the primary one that indwells believers, the union of the three persons is such that the Father and Son also indwell believers.
John 14:18-26, “I will not leave you orphaned;
I am coming to you. In a little while the world will no longer see me, but you will see me; because I live, you also will live. On that day you will know that I
am in my Father, and you in me,
and I in you. They who have my commandments and keep them are those who love me, and those who love me will be loved by my Father, and I will love them and reveal myself to them.” Judas (not Iscariot) said to him, “Lord, how is it that you will reveal yourself to us and not to the world?” 23 Jesus answered him, “
Those who love me will keep my word, and my Father will love them, and we will come to them and make our home with them. Whoever does not love me does not keep my words, and the word that you hear is not mine but is from the Father who sent me. “I have said these things to you while I am still with you. But the Advocate, the Holy Spirit,
whom the Father will send in my name, will teach you everything and remind you of all that I have said to you."
So a) Jesus is coming to the believers, b) Jesus is in the Father, c) the believers are in Jesus, d) Jesus is in the believers, e) believers will keep Jesus' word, f) God will love them, g) God and Jesus will come to them and make their home with them, h) Jesus' words are not His but are from the Father who sent Him, g) in the next sentence, Jesus said that
He said those things, h) the Father will send the Holy Spirit in Jesus' name, i) the Holy Spirit will remind the believers of what He (Jesus) said to them.
One could easily interpret this as the Father is coming to the believers, but they are already in Jesus! And the Father is in them also! So, why do they have to come to the believers if they are already in them? And why does God have to send the Holy Spirit if God and Jesus are already in them? And why do they have to be reminded if the Father and Son are already in them?
There are indeed three persons, but they are defined interchangeably. It is clear that the Godhead is composed of the Father, the Son, and the Holy Spirit. Parsing Scripture to try to prove exactly who the three persons are and how they interact with humanity, particularly believers, is an impossible task.
That is why this thread has over 1,500 posts and will undoubtedly continue on and on and on, with no resolution. The trinity cannot be explained using logic. It is understood by faith alone.