All perfect praise be to Allah, and peace and blessing be upon the Messenger of Allah, his family, and all his companions.
If you committed this action before reaching puberty, then you are not sinful, because you were not obliged by Sheree'ah yet. Ahmed reported on the authority of 'Ali that he said: I heard the Messenger of Allah, sallallahu ‘alayhi wa sallam, say, “The Pen has been lifted (recording deeds) from three : from the sleeping person until he wakes up, from the child until he reaches puberty, and from the insane until he regains his sanity.” [Imam Ahmad]
However, if you committed this action after reaching puberty, then you must repent to Allah the Almighty for the sin you have committed. The conditions of repentance are detailed in Fatwa 86527.
You do not have to tell your cousin what you did with him. Moreover, do not pay attention to any thoughts that come to your mind about that matter; rather, ignore them and keep yourself busy with what benefits you in your religion and your worldly affairs.
Allah knows best.