A cohort can be returned to life in exactly the same ways as any other creatures of its type and condition. There are certainly things that might make it impossible to bring a cohort back, but simply “being a cohort” isn’t one of them—and for that matter, anything that does do it would do the same thing to anyone else.
A lost animal companion, cohort, familiar, or follower can be raised or resurrected with spells such as raise dead, resurrection, or true resurrection. For a cohort or follower with character levels, these kinds of spells give the character one or more negative levels—a price worth paying if the alternative is death.
(Archives of Nethys, Campaign Systems / Companions / Reviving and Replacing Companions, which cites Ultimate Campaign pg. 147)
This was true before Ultimate Campaign, but Ultimate Campaign was the first time they said it explicitly (that I can find). Before that, we would have had to rely on the lack of any rule that prevents raising a cohort.