Need advise.

I have a 7 month old and I’m trying to get him to sleep in his own crib but even if I lay him in there while he’s tired and almost sleeping he will roll over and he’ll just bang his head on the crib sides. He wakes up 3-4 times a night