The fact that your son and his friends have been doing this for years with the consent of a resident of the apartment (who is presumably about the same age and therefore an adult who can give permission), might very well be a defense to this charge. If he is telling the truth about why he tried to enter on this specific occasion, this is a case which should be vigorously defended and not plea bargained unless it is reduced to the lowest form of trespassing discussed below.
Since another person was in the apartment, and if your son was not armed with a weapon, the burglary law with which he is most likely charged is in Chapter 952 of the Connecticut Penal Code:
Sec. 53a-102. Burglary in the second degree: Class C felony. (a) A person is guilty of burglary in the second degree when such person (1) enters or remains unlawfully in a dwelling at night with intent to commit a crime therein, or (2) enters or remains unlawfully in a dwelling, while a person other than a participant in the crime is actually present in such dwelling, with intent to commit a crime therein.
Note the bold phrases requiring intent to commit a crime. What your son did would be a burglary in Connecticut only if he actually entered the apartment and had intent to commit a crime in there when he did. If he is telling the truth that he did not enter (even sticking his hand through an open window, however, would constitute entry) and did not intend to commit a crime inside the apartment, it was not a burglary.
Even if he didn't actually enter, the DA might try to say it was an attempted burglary because he tried to enter with intent to commit a crime. Once again, however, if he had no intent to commit a crime, it was not an attempted burglary, either.
There are also several forms of criminal trespass in Connecticut, one of which might apply here:
Sec. 53a-108. Criminal trespass in the second degree: Class B misdemeanor. (a) A person is guilty of criminal trespass in the second degree when, knowing that such person is not licensed or privileged to do so, (1) such person enters or remains in a building, or (2) such person enters or remains on public land.
(b) Criminal trespass in the second degree is a class B misdemeanor.
There is, however, an affirmative defense to trespass which applies here if your son and his friends are telling the truth:
Sec. 53a-110. Affirmative defenses to criminal trespass. It shall be an affirmative defense to prosecution for criminal trespass that: ... (3) the actor reasonably believed that the owner of the premises, or a person empowered to license access thereto, would have licensed him to enter or remain, or that he was licensed to do so.
If your son had permission from his friend ("a person empowered to license access thereto") to climb in the window, they have been doing it for years and the friend is willing to confirm that in trial testimony, your son has an affirmative defense and there is no crime of trespass.
Finally, there is a very low level form of trespass which is only an infraction (like getting a traffic ticket):
Sec. 53a-110a. Simple trespass: Infraction. (a) A person is guilty of simple trespass when, knowing that he is not licensed or privileged to do so, he enters any premises without intent to harm any property.
(b) Simple trespass is an infraction.
Assuming again that your son is telling the truth, this is the offense at most
for which he should be convicted.
Of course, convincing the DA, the court
and/or a jury that he is telling the truth is complicated by the fact that he ran and left his backpack behind. However, the fact that his friend is willing to support his affirmative defense (that he had permission to enter the apartment through the window) is very strong evidence that, if believed by a jury, will result in an acquittal
Everything considered, if the DA is willing to reduce the charge to an infraction trespass with a small fine as punishment, the risk of conviction on a more serious charge would justify pleading guilty to that lesser offense. On these facts, however, there is no way your son should accept even a misdemeanor conviction, much less a felony.