Consider the random variables $X, Y$ defined on the probability space $(S, \mathcal{A}, \mu)$ taking value respectively in the Borel spaces $(\mathcal{X}, \mathcal{B}_{\mathcal{X}})$, $(\mathcal{Y}, \mathcal{B}_{\mathcal{Y}})$.
Consider a measurable function $f:\mathcal{X}\times \mathcal{Y}\rightarrow \mathbb{R}$.
Consider $f(X,Y)$.
How should I think about $f(X,Y)$?
(1) $f(X,Y)$ can be thought of as a random variable $W:S\rightarrow \mathbb{R}$ such that $W(s)=f(X(s), Y(s))$.
(2) $f(X,Y)$ can be thought of as a deterministic function $f:\mathcal{X}\times \mathcal{Y}\rightarrow \mathbb{R}$ assigning $f(x,y)$ to each $(x,y)\in \mathcal{X}\times \mathcal{Y}$.
(3) Can $f(X,Y)$ be thought as a random function, i.e. as a random variable taking value in a function space?