Yes it comes in Adhyatma Ramayan which is inside Brahmanda Puran. This takes place after coronation of Lord Rama. Lord Rama felt compassion toward Lord Hanuman and hence grants the knowledge .
This goes as following. First Shri Ram tells Sita to give Brahmn Gyan to Hanuman::
Adhyatma Ramayan 1.30-1.35
He is fit to be taught about the knowledge of Brahmam,
For among those who seek that knowledge he is the first.
When at that time after Sri Rama told like this,
The Goddess called Hanuman and told him thus,
“The leading stone of the crown worn by valorous heroes,
The greatest among devotees of Rama , please hear what I say,
Please decide within your mind that God Rama is the,
The divine joy , the one and only one , one who does not have a second , the divine Brahmam,
The one who does not move, One who is not attached to anything, One who is only essence,
And that thing which cannot be known in spite of determination,
You please understand that this God Rama is pure , without stains,
One without properties , one who is not having any feelings,
One who does only good , One who is peaceful , One who is the divine soul, one who is forever
A thing which does not have any birth or death and he is the divine Brahmam.
Please understand that God Rama is the cause of all , one who is spread everywhere, one who is
the soul of all,
One who is everything , One who is the God of all, one who is witness of all, one who is forever,
One who is everything and basis of all , one who is spread in all gods and a without sensations.
Now I would tell you the principle of mine in real terms,
To you I have become the primeval causal basis,
And my husband who is the divine God
Allows me to create anything just by his presence.
All those which have been created by me due to his presence,
Are understood by foolish people as the real divine form,
Not understanding that his form does not have any birth ,
For only those who have realized him will know About it.
In this earth , in the clan of the sun God , in Ayodhya,
The God of all was born in the form of Sri Rama.... >
Then after some description of Lord Rams deed by Goddess Sita, Lord Ram himself imparts the knowledge to Hanuman. It goes as following::
Adhyatma Ramayana 1.44-1.56
"After the philosophy of the existence of Rama,
Was explained by Goddess Sita to the son of Anjana
Lord Rama with a pretty smile told him,
“ The souls that we all see is but the refection,
Of the form of the divine soul that exists everywhere.”
Oh great monkey , My lustrous illusion ,
Without any doubt has the image in you,
Like in each and every lake , the great sky ,
Can be directly seen by you , and similar to that,
The real Divine Brahmam , the form for which.
The divine God is himself the witness is very stable, my friend,
You should understand the principle behind me,
By the great Vedic sayings like “You are That”,
And my devotee due to the grace of Guru,
When he understands this , without any doubt,
Would reach me and my form.
“Those who are not interested in my devotion , jump ,
Into all places where science is mentioned and love that place ,
To those who do not have devotion, even after hundred thousand births,
They would not get knowledge of philosophy and salvation,
Do not inform those men who do not have devotion to me,
This fact which has been told by me as God anytime.
There is no divine advice which is above this.”
Thus Lord Shiva told Goddess Parvathi,
About the greatness of Rama , which is holy and held as great secret,
And which was told by the real Lord Rama himself to the son of wind god,
And it leads to salvation , it destroys sins , that which starts killing of darkness of the heart,
And which is the meaning of all Vedanthas, And is the principle behind Lord Rama.
All these divine words which were taught to lord Hanuman,
If read by a man always along with great devotion,
Without any doubt will set him free."