HERMON — Authorities say a Maine man who exchanged gunfire with police was shot in the leg, but died from a self-inflicted gunshot wound to the head.

Police say the episode unfolded Sunday night at the home of 24-year-old Michael McKay in Hermon, where he returned after allegedly threatening some people in Kenduskeag.

Brenda Kielty from the Maine attorney general’s office says an autopsy indicates McKay died from a self-inflicted gunshot wound to the head. He also was shot in the leg by a member of the state police tactical team who has been placed on leave during the investigation.

The incident began with a Kenduskeag man claiming McKay threatened a group and fired shots into a car. Police pursued him to his home, where there was a fatal exchange of gunfire.