BOSTON (CBS) – A mother accused of dumping her newborn baby in a Dorchester trash can appeared in court Monday afternoon. Marie Mercier is charged with attempted murder and the reckless endangerment of a child.

Prosecutors said the 33-year-old was cooking or cleaning at a home in Dorchester on Friday and was pregnant when she arrived.

READ MORE: UPDATE: St. Pete Man Identified In Fatal Saturday Shooting

Witnesses told police she went into the bathroom for more than an hour and they heard a baby crying. She allegedly came out with a leather bag and refused help.

Prosecutors say video from a pizza shop nearby shows her reaching into the bag, taking out a plastic bag and putting it in a trash barrel.

READ MORE: Pasco Schools May Eliminate Mask Requirement For Students By The End Of April

The baby, a boy, was inside the plastic bag. A woman heard crying from the trash can and alerted EMS who brought the baby to the hospital. The baby is doing well.

Police say when they confronted Mercier, she initially denied any involvement but then told them she thought the baby was dead.

MORE NEWS: Florida Man Sentenced To 40 Years For Sexual Battery Of A Child

The defense says mental health issues and postpartum depression may play a role in this case.