Motivated by subdiffusive motion of biomolecules observed in living cells, we study the stochastic properties of a non-Brownian particle whose motion is governed by either fractional Brownian motion or the fractional Langevin equation and restricted to a finite domain. We investigate by analytic calculations and simulations how time-averaged observables (e.g., the time-averaged mean-squared displacement and displacement correlation) are affected by spatial confinement and dimensionality. In particular, we study the degree of weak ergodicity breaking and scatter between different single trajectories for this confined motion in the subdiffusive domain. The general trend is that deviations from ergodicity are decreased with decreasing size of the movement volume and with increasing dimensionality. We define the displacement correlation function and find that this quantity shows distinct features for fractional Brownian motion, fractional Langevin equation, and continuous time subdiffusion, such that it appears an efficient measure to distinguish these different processes based on single-particle trajectory data.