I am a beginner in statistics, and am self-studying. I have trouble understanding the marginal density function. I was wondering if any of you could please kindly help me with this problem.
How can I determine the marginal density functions fx and fy? And also the marginal means mx and my.

Start with making a picture in $\mathbb R^2$ drawing the lines $x=-1,x=1,y=-1,y=1-2x$, i.e. the borders of the area on which $f$ takes value $\frac14$. Note that equality $y=1-2x$ can also be written as $x=\frac12-\frac12y$.
In general for a fixed $x\in\mathbb R$: $$f_X(x)=\int_{-\infty}^{+\infty}f_{X,Y}(x,y)dy\tag1$$and for a fixed $y\in\mathbb R$:$$f_Y(y)=\int_{-\infty}^{+\infty}f_{X,Y}(x,y)dx\tag2$$
If $x\notin[-1,1]$ then $(1)$ gives $0$ and if $x\in[-1,1]$ then:$$f_X(x)=\int_{-1}^{1-2x}\frac14dy$$ (Have a look at your picture to get some insight concerning the borders).
If $y\notin[-1,3]$ then $(2)$ gives $0$ and if $y\in[-1,3]$ then:$$f_Y(y)=\int_{-1}^{\frac12-\frac12y}\frac14dx$$ (Have a look at your picture to get some insight concerning the borders).
Work this out.
Further we have:$$\mathbb EX=\int_{-\infty}^{+\infty}xf_X(x)dx=\int_{-1}^{1}xf_X(x)dx$$and: $$\mathbb EY=\int_{-\infty}^{+\infty}yf_Y(y)dy=\int_{-1}^{3}yf_Y(y)dy$$
Work this out.