With stories, anecdotes and pages from a diary, Amitav Ghosh’s new book illustrates the causes close to his heart from climate change, oceans to migration