Maria Shirinkina and Vladimir Shklyarov of the Mariinsky Ballet perform in “Cinderella.” (Katherine Frey/THE WASHINGTON POST)

With one look at the stage before Alexei Ratmansky’s “Cinderella” began Tuesday night, you knew you weren’t in for a fairy-tale treatment. The drop curtain shows a crowded, crudely painted city skyline, a prison of dark vertical lines and cramped tenements.

You can’t say he didn’t warn us. Ratmansky threads the theme of narrowness and confinement all through his ballet, from the steel-bounded dump where the heroine lives with her vulturous stepmother to the stiff, emotionally constipated posturing of the guests at the prince’s ball. With stark, modernist decor suggestive of the lean years of the 1930s — echoed in the thin, clingy costumes that emphasized bony angularity — the production’s design credo is total exposure. And what’s exposed is deliberately unlovely, for the most part.

This is not your daughter’s “Cinderella.” It may not be yours, either; empty seats materialized after each intermission. (With two of them, it’s a long evening.) If you found yourself wondering why the Mariinsky was bringing this work to the Kennedy Center Opera House for a second time, after its 2005 showing there, one reason may be the nostalgic connection that the ballet company feels toward the center itself.

Ten years ago, as he was readying “Cinderella” for its world premiere in St. Petersburg, Ratmansky traveled here with the Mariinsky (which was inaugurating its annual Washington visits with “Sleeping Beauty”) and finished making the ballet in the Kennedy Center’s rehearsal studios. Yuri Fateev, the company’s deputy director, related this to me with evident warmth Tuesday, saying he recalls the very studios in which Ratmansky created specific sections of “Cinderella.”

To the rest of the world in 2002, Ratmansky wasn’t yet the celebrated choreographer that he is now. But to those who knew him, as Fateev did, his gifts were obvious. It’s no surprise that memories of watching him in the throes of creativity left such a mark.

“Cinderella” is not a complete success. But it’s undone more by problems with Prokofiev’s music than by weaknesses in the concept. Ratmansky’s treatment echoes the sharp and piercing modernism in the score, which contains more aches and groans than fairy dust. But the musical world is not as fully realized as it was in “Romeo and Juliet,” which Prokofiev produced first, with more feeling. “Cinderella’s” music seems to wind around and around itself in spots, and in the face of its redundancies Ratmansky’s ideas are stretched thin. Solos at the ball for the stepsisters and stepmother run on to the point of dullness.

If the sharply restricted style wasn’t the most flattering vehicle to show off the strengths of the Mariinsky Ballet, the dancers dived into its grotesqueries with appetite. Ekaterina Kondaurova’s stepmother slashed across the stage, limbs like daggers.

With a discipline that may have been hard for the rest of the cast to swallow, Ratmansky reserved all aspects of warmth and beauty for two characters alone: Cinderella and her prince. His mistreated heroine dreams only vaguely of love. Her great hope, as Maria Shirinkina made clear in this role Tuesday, was for freedom. In a world of tight, clenched body language, freedom equates to grace. And so we saw Shirinkina tentatively soften and round her movements in her first solo, and then produce a glorious, full-blown unfolding of grace in her dance at the ball with Vladimir Shklyarov’s prince.

Shklyarov, who made a blazing entrance in white (all hail the Good Humor Man!), responds to Shirinkina by toning down his astounding virtuosity. In the ballet’s final moments, as Shklyarov opened up and grew more tender, you saw anxiety pass through Shirinkina, and then float away. And the two ended up in each other’s arms . . . on the floor. Not exactly a fairy-tale ending. But this was not exactly a fairy tale — it had hard edges, like life.

This production continues through Sunday, with cast changes.