HELP!!! Penis gets soft when trying to put on condom

So me and my boyfriend (both 17) just attempted to have sex with each other for the first time. Both of us only has had one other partner but this was his first time using a condom. He usually is always horny and gets hard instantly as when I touch him but when we tried putting the condom on he would get soft. We tried like with 3 diff condoms and the same thing happened. How can we prevent this???