BEDFORD HILLS, N.Y. (AP) — Jennifer Dumas sits on a sofa, her smiling 6-month-old girl on her lap. The room is full of bright toys and children's books. A rainbow-colored activity mat is on the floor, and Winnie the Pooh is painted on the walls.

It looks like any other nursery, except that there arebarson the windows and barbed-wire fences outside the austere brick building.

New York's maximum-security Bedford Hills Correctional Facility is one of the very few prisons in the U.S. that allow inmates and their babies to live together, a century-old approach that not all corrections experts agree is the best way to deal with women locked up while pregnant.

Mothers who get such a chance say it's better than the alternative: In most prisons,babies born behind bars must be given up within a day to a relative or foster care.

"Before I came here, I thought it was a terrible idea. A baby in prison? No, thank you," the 24-year-old Dumas said as her daughter, Codylynn, gleefully rocked in a bouncy seat. "But it's actually wonderful to be able to spend this much time with my little girl. ... I'm blessed to be able to go through this."

Nobody thinks raising babies behind bars is ideal, and some worry that the children could be scarred by the experience. But some advocates say that the practice allows mother and child to develop a vital psychological attachment, and that the parenting classes and other practical instruction help the moms stay out of trouble when they get out.

About 112,000 women are in state and federal prisons, mostly for drug or property crimes. And an estimated 1 in 25 are pregnant when they enter, according to the nonprofit Sentencing Project. But there are no national statistics on the number ofbabiesborn to inmates.

Of the more than 100 women's prisons in the U.S., there are eight nurseries. While nearly 100 countries, including South Sudan and France, have national laws that allow for incarcerated mothers to stay with their babies, the U.S. is not among them.

Dumas was three weeks pregnant when she was arrested last year, along with her boyfriend, on charges they tried to steal a safe packed with $32,000 in cash and jewelry. Her baby was born just days after she took a plea bargain on attempted burglary charges that sent her to Bedford Hills, about an hour north of New York City, for up to two years.

She is now among 15 carefully screened new mothers allowed to serve up to 18 months of their sentences in a nursery unit that includes a communal playroom stocked with toys and mother-and-child rooms equipped with a single bed and a crib. The walls are painted with rainbows, fluffy clouds and jungle and barnyard scenes. The nursery currently has 16 babies, including a set of twins.

During workday hours, the babies are taken across the street to a day care center, where they are watched by staff and other inmates while the moms go to school or vocational programs.

But there are constant reminders it is a prison. Armed officers patrol the unit. And the moms know their babies can be taken away for such infractions as fighting or even leaving a toy in a crib while the baby sleeps.

"It's still scary," Dumas said. "At any given point if you do what you're not supposed to your baby could get sent home."

Some women have been dropped from the program from time to time for breaking the rules, but corrections officials and advocates said they could not recall any instances in recent years in which a baby was harmed.

Still, some argue that prison should be reserved for punishment and that women should instead consider putting their children up for adoption.

"The focus should be on what's best for the baby," said James Dwyer, a law professor at the College of William & Mary who has written a paper on the topic. "There is skepticism about these women being adequate parents."

Columbia University researcher Mary Byrne, who spent years studying mothers and children who started life in Bedford Hills, said that the youngsters formed critical attachments to their mothers and that a second study after they were released found they were no different from children raised entirely on the outside.

"Many people would assume any exposure to prison would cause problems ... they'll be exposed to violence and horrible people, it will scar them," she said. "But that's not what we found."

Sister Teresa Fitzgerald, the Roman Catholic nun who runs Hour Children, the nonprofit organization that operates Bedford Hills' nursery, put it more bluntly: "Babies belong with their mother. In a palace or a prison, they don't know and don't care as long as they feel loved and supported."

The nursery is operated under an annual contract with the state of about $170,000, the correction department said. It would cost $480,000 a year to put 16 babies in foster care, according to state figures.

Bedford Hills' recidivism rate for women in the nursery program is fairly typical of such programs, at 13 percent versus 26 percent for all female inmates at the prison, according to a report by the Women's Prison Association, an advocacy group.

Bedford Hills has the oldest continuously operating prison nursery in the country, opened in 1901. There were many nurseries years ago, according to Elaine Lord, the former superintendent. But they fell out of favor amid a huge influx of prisoners in the 1980s and a shift in thinking that said the privilege of living with your baby was inconsistent with the concept of punishment.

Most of the nation's prison nurseries have cropped up in the past 20 years.

The nursery at the Indiana Women's Prison houses up to 10 mother-infant pairs for up to 18 months. In South Dakota, a child can stay only 30 days. In Washington state, it's three years. The Decatur Correctional Center in Illinois opened a nursery in 2007, and 73 moms have participated.

In Decatur, Kalee Ford, who is about 26 weeks pregnant and in prison on a drug-related conviction, already has been accepted into the program and is taking prenatal courses. She said she wasn't the mother she could have been to her two other children because of methamphetamine. The program is giving her hope that she can clean up for good.

"I believe that everybody deserves at least one chance to fix mistakes that they've made," she said. "My children didn't do this, and they deserve to have me back."

At Decatur, Bedford Hills and other programs, mothers-to-be are selected based on their crimes and whether there is any history of child abuse.

Many advocates question why such women need to be incarcerated at all. Typically, women accepted into these programs are nonviolent offenders serving fairly short sentences — ideal candidates for less-expensive, halfway house-like programs for mother and child.

After their sentences are up, almost all of the mothers at Bedford go to a live-in halfway house in New York City run by Fitzgerald's organization that also helps with day care and jobs. Mothers say it's a golden ticket.

Dumas, who has a son on the outside, hopes to go there, too.

"It's a way to get on my feet, try being a parent again on the outside but with a safety net," she said. "I don't know anyone who gets that."