Can i put a check from someone else into my account?

My bank account? So my baby daddy (boyfriend) got a check from the state and he wanted to give me for our baby. For his stuff because i am pregnant . But can i get it and take it to my bank to put into my bank account? Or how does that go? Does it have to be my own checks and with my own name on them?