[Warning: This story contains spoilers from Wednesday's episode of USA Network's Mr. Robot.]

Midway through its second season, one of Mr. Robot's biggest mysteries has been solved (sort of.) Speculation had run rampant online among viewers that something was happening with Elliot (Rami Malek) different from what was being depicted onscreen. At the very beginning of the season, The Hollywood Reporter questioned whether Elliot was in an institution, or whether he was in on the twist. The truth is a little bit of both, it seems, as the sixth episode of season two revealed Elliot finally coming to grips with his reality. He's not living with his mother, but in jail. The mom viewers have met is actually a security guard, and his stark lonely room is actually a jail cell. (Yes, he even sports an orange jumpsuit.)

The revelation was reminiscent of the season one twist that has since come to define the show: that Mr. Robot is actually Elliot's dead father and a figure of his imagination. As Elliot said in Wednesday's episode, "Sometimes you need illusion to gain control." So what will Elliot's confession mean going forward? Why was now the right time for him to tell the truth? And how often should viewers be expecting these kind of reveals from the notoriously "mysterious" show? THR spoke with creator, showrunner and director Sam Esmail about all that and more.

Was it always supposed to be prison? Was there ever a time where he would be in a psych ward or a different type of controlled environment?

No. I think, obviously from the first season, we knew the fate of Elliot by the end of that season going into the second season, and when we started breaking up that storyline — knowing Elliot and knowing his character and knowing how he sort of reprograms, or that he has the capability of reprogramming his surroundings to cope with life — we felt it would be an authentic way of telling this version of his present tense, this storyline for the second season. That was sort of the jumping-off point and then from there, we kind of debated: What would he transform that to? And then it sort of led to the biggest disciplinarian in his life, being his mother, and that's how we came to that mom's townhouse storyline for the second season.

Why do you think this was the right time and the right episode to reveal Elliot's true surroundings?

So what we did what was, initially the thing that when we planned out Elliot's arc for the season, the first thing that I really wanted to do was sort of explore how Elliot was going to reconcile this alter-ego that he is no longer in control of. What are the stages of that battle, that internal conflict that he's going to have to resolve before he's able to do anything else? It felt completely dishonest to us for him to go about his life in the world and not deal with this issue. It sort of, like, became the big headline of Elliot's psychological process. Which is part of the reason why the environment worked so well, so we went through these stages. Obviously, we have a psychologist as our consultant and we went through the stages of what we think the battle, the coming to terms, the overcompensating — the journey that essentially Elliot goes through to come to that moment of finally accepting that maybe he can live with this other personality. That's basically how we kind of plotted out that this was the halfway mark of the season and that once he's come to that realization, now he can be set free.

What does that mean for him going forward now that he is set free?

Well, now with this new dynamic where he's no longer battling himself, where he's sort of made peace with himself and with Mr. Robot as his alter-ego, that's going to change how he sort of operates in the world and literally now when he's also simultaneously being freed from prison, now we'll actually see him get to engage back into the main plotline, but with that new dynamic intact.

One of the big taglines for season two of the series has been "Control is an illusion." When Elliot is explaining why he lied, he kind of flips that by saying "sometimes you need illusion to gain control." What is the meaning behind this?

Yeah, I think, for me, what Elliot does is something that I think everybody to a certain extent would be doing. There are lies that we can tell ourselves to comfort ourselves. They're not necessarily even lies but they're little things to comfort us about the world, about our place in the world, about our existential conversations that you could be having with yourself. But of course in Elliot's worldview, it's taken to a much more extreme case, but I think in a more relatable way, we all have those little things that kind of comfort us even though they may not be true, but those illusory things we sort of invent to keep us going, to cope with certain trauma that we have or certain issues. Anything from like a minor conflict at the office to something deeper and more traumatic. We have these little inventions and we use those to cope and, in terms of Elliot, that becomes this new world, this very fantastical world, but in terms of maybe everyday life, it becomes these little things that we kind of create to cope with things, so it's just a different way of looking at how people mange their coping mechanisms.

Since the beginning of the season, there had been some speculation about what was really going on with Elliot. Some people speculated he was in a psych ward, for example. How much were you paying attention to that? How concerned were you about people figuring this out knowing what you had planned?

The things about reveals is that, obviously when they're surprising, they can be really impactful, but when they feel like a cheat, they're very parable and you're always having to balance those two. You want the reveal to be earned and you don’t want it to feel like a cheat and you hope that it surprises people. That's the part that's up to the audience, that's up to the particular viewer that's watching that show, that movie or reading that book and you can't control where their brain goes as they're experiencing the show.

One of my favorite films is The Usual Suspects. Obviously I've seen it a ton of times, I know that the big reveal is at the end. I still enjoy it on the second and third viewing and that to me, it doesn't take away from … if we did our jobs right and we executed it and ultimately, again, made it about Elliot's emotional journey, knowing the reveal or not should not take away from it. Maybe the impact of the reveal would either be lessened or be greater had you not known it but again, because we're not treating it like a 'gotcha' moment, and it was never intended that way and it really is about Elliot's journey, and the way that he was using this device to really cope, for me, it's almost like a second viewing for the first time. So that's how I sort of take it when people are good at online theorizing. I feel like there's a whole different level of engagement that certain people obviously jump on and I think that's great. I think that means that they're excited about the show and they want to analyze it and figure it out and that's awesome. And if they figured it out beforehand, I hopefully don't think that takes away from the experience.

With this reveal comes comparisons to last season's big reveal about Mr. Robot and now some people are wondering whether they should expect a similar kind of reveal every season. What are your thoughts on that discussion?

Here's what I'll say: The show has a lot of mystery to it. There's a lot of questions that we haven't answered and it all sort of depends on what the big twist or the big reveals are. So for me, in a lot of ways, in the first season, the Darlene reveal became a bigger sort of impact on people than the Mr. Robot reveal and so there are degrees to what you're talking about. And because this show is so shrouded in mystery, because we don’t understand everyone's motivations, because there a lot of questions about what's going on behind the scenes, we are going to always have reveals that may surprise, may shock or may not, and I think that's kind of in the DNA of the show. I don’t know about this one-big-thing every season because I think we tend to have multiple things because, again, of that mysterious nature of the show.

Speaking to that, there are at least two burning questions at the moment: Why is Elliot in jail, and whether Tyrell Wellick is really dead? When will we get answers?



We'll definitely answer those questions by the end of the season.

Congrats on the renewal for season three. Now that you know you're coming back, do you think you'll direct all the episodes again next season?

Yeah, that's the plan for next season.

Watch the reveal, below.

Mr. Robot airs Wednesdays at 10 p.m. ET/PT on USA Network.