I'd also wondered about this. I think it comes down to three things:
- He initially ended up with the Snow loyalists by chance. He didn't make a deliberate decision to go out of his way to side with them, he simply hauled the corpse into his room with them before it was 100% clear what had happened, because it was the closest suitable space. It looked to me that they weren't even 100% sure he was dead and beyond saving until examining him on the table. When the facts were confirmed, he was with them by default, unless he actively kicked out these honest people and their admirable dead friend from his room
- He's a stubborn good guy who's not afraid to take risks or support a doomed cause. We've seen plenty of times that he won't hesitate to risk his life for people he's loyal to or a cause he believes is right, no matter the odds against them. For example, barely knew Gendry but threw himself into championing him with a similar lack of hesitation.
He didn't have any better offers. We saw him finally give up on Stannis when he saw Melisandre at the end of the last series. Davos said himself that the authoritarian Alliser was exactly the kind of man he'd spent his life avoiding, so staying under his rule was no option. He was hardly going to elope with Melisandre, who he never liked and who was just as lost as him. Travelling North beyond the wall was not a viable option, and travelling South would take him through lands ruled by his enemies and wildlings who knew him only as the second in command to the man who routed them, tried to make them kneel and burnt their leader.
These leaderless lads are the closest he has to friends for miles. His only realistic alternative was go East to the coast and try to find someone in need of a smuggler, but he'd be as likely to meet old enemies from his smuggling days as old friends, and he takes pride in having put that life behind him. Better to be Davos the hero one more time than slip back into being Davos the criminal who deserves to have his fingers cut off.
Given all the above, it's easier to imagine him adopting the (presumably?) doomed cause of Snow's loyal friends, than it is to imagine him saying "Screw you guys, get out of my room and take this honest man's corpse with you. I've got a busy day of staring forlornly into the middle distance to attend to".
For more on why he seems emotionally invested in what happens to Jon, see Why does Davos care about Jon so much? (contains episode 2 spoilers)