In this paper, the anomalous diffusion processes are modeled with partial differential equations of the fractional order that are then discussed in details. The anomalous diffusion can be characterized by the property that it no longer follows the Gaussian statistics and in particular one observes a deviation from the linear time dependence of the mean squared displacement. This is the case for many different phenomena including, e.g., the translocation dynamics of a polymer chain through a nanopore, charge carrier transport in amorphous semiconductors, laser cooling in quantum optical systems to mention only few of them. In this paper, we consider the case of the anomalous diffusion that shows a power-low growth of the mean squared displacement in time. Our starting point is a stochastic formulation of the model in terms of the random walk processes. Following this line, a continuous time random walk model in form of a system of the integral equations of convolution type for the corresponding probability density functions is introduced. These so called master equations can be explicitly solved in the Fourier-Laplace domain. The time-fractional differential equation is then derived asymptotically from the master equations for the special classes of the probability density functions with the infinite first moment. For the obtained model equation and its generalizations the initial-boundary-value problems in the bounded domains are discussed. A special focus is on the initial-boundary-value problems for the generalized time-fractional diffusion equation. For this equation, the maximum principle well known for the elliptic and parabolic type PDEs is presented and applied both for the a priori estimates of the solution and for the proof of its uniqueness. Finally, first the existence of the generalized solution and then the existence of the solution under some restrictions are shown.