This statement was in a narrative regarding a man who was asking “what he can do to inherit eternal life”(Mk. 10:17-29). See also Matthew 19:24; Luke 18:25.
And for the context, please notice the emphasis of the question on “man” Mk. 10:17,”what shall ( I ) do that ( I ) may inherit eternal life?. It was about having “self” doing something to attain eternal life.
Also, this trust in what “man” can do was reiterated in Luke 18:9-30, in v-9, “And he spake this parable unto certain which (trusted in themselves) that they were righteous, and despised others…”.
Moreover, notice in Mk 10:28-29, “Then Peter began to say unto him, Lo, we have left all, and have followed thee. And Jesus answered and said, Verily I say unto you, There is (no) man that hath left house, or brethren, or sisters, or father, or mother, or wife, or children, or lands, for my sake, and the gospel’s,”. Even when Peter and the disciples claimed that they (humans) left material things for the sake of Jesus’ and the gospel, Jesus categorically denied that claim.
It appears that there was this belief predominant at that time that man can attain “eternal life” with “good works”. Even now, some think this way.
The focus of Jesus’ answer was to emphasize that “eternal life” is impossible for man (even rich man, or apostles they may be) to achieve on his own. That the “righteousness of God” is not anchored on man; it is a gift of God the Father and by grace. All mankind will die one way or another as “it is once appointed unto man to die and afterwards, the resurrection.” (Heb. 9:27 ). As to eternal life after resurrection, this can be gifted to us only by God the Father. While Jesus is the “only specific man chosen by the Father to effectuate his plan, he himself died as a man and was “powerless”. Jesus proved this concept by dying himself and, being dead, was dependent on the Father to resurrect him so that we “shall(future) be saved by his life”(Rom. 5:10).
And Jesus knowing that those around him saw him as a “man”, he therefore had to deflect and redirect to a “default answer”, that no man, yes “none is good but God”. Eternal life can only be given by God the Father (John 3:16). Jesus was here in this narrative, to honor God, his Father. And, you and I now know that man-Jesus’ role was to follow the will of the Father, as in “not my will but your will”(Lu. 22:42)
With the context thus explained, we can now understand Mk. 10:23-25 “Children, how hard is it for them that trust in riches to enter into the kingdom of God! It is easier for a camel to go through the eye of a needle, than for a rich man to enter into the kingdom of God.”
The preceding is clear as to the wisdom of Jesus’ way of answering the question, “What can man (and for that matter “any man”) do to inherit eternal life?” No man can. It is “frank cluelessness”, silly and preposterous to even think that man can attain eternal life on his/her “own works”. It is so ridiculous that the gravity of there ignorance was displayed by him equating their argument to “..it is easier for the camel go through the eye of a needle”.” But Jesus said, “With men it is impossible, but not with God: for with God all things are possible.” (Mk.10:27). Even, the counter argument of a Peter and disciples notwithstanding( Mk.10:28-29).
Through man-Jesus, his death reconciled us to the Father and having been resurrected he went to the Father to receive the promise of the Holy Spirit. This is the Holy Spirit given as a gift as promised to YHVH ELOHIM, the Creator Logos who incarnated to Jesus. This HS was not a reward for Jesus’ death; again Jesus’ death was for “reconciliation”. But the “faith (of) Jesus” on the Father whose promise would be kept for sure, as a “gift by grace”.
The Persians expressed the concept of the impossible by saying it would be easier to put an elephant through the eye of a needle. The camel was a Jewish adaptation (the largest animal in Palestine was a camel).
The most likely explanation is that Jesus was using hyperbole, a figure of speech that exaggerates for emphasis. Jesus used this technique at other times, referring to a “plank” in one’s eye (Matthew 7:3-5) and swallowing a camel (Matthew 23:24).
Indeed, eternal life is not to be attained through “any man’s own works” it is a gift of God the Father.