Yup! As the FAQ says
"You can make your own, or you can just use ones made by others and that are available to use. You can even use assets from commercial games, we are making fangames after all.
Just make sure to give proper credit when needed, and state which assets you're using that you do not own."
If you need assets for a 2D Mario fangame specifically, we have a pretty large library of them on our website.