OK, so my knowledge of probability theory sucks and I'm trying to figure out how to justify this theoretically. Assume we have random variables $X_1,\ldots,X_n$ and a random variable $I$ with values in $\{1,...,n\}$. Then intuitively
$$\mathbb{P}[X_I=x\mid I=i] = \mathbb{P}[X_i = x].$$
How do I justify this from the definition
$$\mathbb{P}[A\mid B] = \frac{\mathbb{P}[A\cap B]}{\mathbb{P}[B]}?$$
It's simply:
$$\begin{align}\mathbb P(X_I=x\mid I=i) & = \frac{\mathbb P(X_I=x\cap I=i)}{\mathbb P(I=i)} & \text{by definition} \\[1ex] & = \frac{\mathbb P(X_i=x\cap I=i)}{\mathbb P(I=i)} & (X_I=x\cap I=i) \equiv (X_i=x\cap I=i) \\[1ex] & = \frac{\mathbb P(X_i=x)\mathbb P(I=i)}{\mathbb P(I=i)} & \text{by independence} \\[1ex] & = \mathbb P(X_i=x) & \text{cancelling common terms in the quotient} \end{align}$$
So your intuition served you well.
We could define sets of outcomes ($\omega$) in the probability space $\Omega$ for the real valued random variables $X_1, \ldots X_n$ and $I$ such that $$\begin{align} A & \equiv \left\{\omega \mid \bigvee_{k=1}^n (X_k(\omega)=x\wedge I(\omega)=k)\right\} \\ & \equiv \bigcup_{k=1}^n \left\{\omega \mid X_k(\omega)=x\wedge I(\omega)=k\right\} \\[2ex] B & \equiv \{\omega \mid I(\omega)=i\} \\[2ex] \therefore A\cap B & \equiv \{\omega\mid X_i(\omega)=x\wedge I(\omega)=i\} \end{align}$$
But the more compact notation is generally understood; that the probability of random values being a certain value, or a range of values, is the probability measure of the set of outcomes where such happens.
That is, for instance, $\mathbb P(I=i) = \mathbb P(\{\omega\mid I(\omega)=i\})$.