A second referendum is not without it's problems though.
First, what would the questions be? Would they include an option for No Deal Brexit (which is what it seems the majority of leave voters really want)? If it did not include that then the Leave voters would probably protest endlessly and with great anger to say that the referendum was rigged ... and last time that Leave majority was 17 million people, so that would be massive and very angry mass of society.
This one has two neat solutions.
First solution, ranked choice. You're presented with three options: No Deal Brexit, Ratify the May's deal, Revoke Article 50, rank two in order of prefference. If your first pick is not among the top two, your vote goes to the second choice, the one that has at least 50% plus one vote wins.
Since this is Brexit you should also add a tiebreaker: if both options are even at that point, the one with more first ranked choices wins. Just to be safe and all.
Second solution, two separate questions on a ballot or even two separate ballots. The first one asks whether to ratify the deal in a simple yes/no choice, the second asks the question "Regardless of how you voted on the first ballot, if the will of the electorate is not to ratify the deal, would you perfer a No Deal Brexit or Revoking Article 50?", again a simple binary choice.
The first one is technically more difficult, but entirely doable. The second is easy to do and favors Brexiteers, they only have to win one of two referendums, Bremainers need both. Bremainers might consider ratifying the deal an acceptable compromise just to avoid the very risk of a no deal Brexit. How to word the referendum is trivial. The main problem with a second referendum is completely different, see below.
Would the government take the necessary legal step of making the new referendum legally binding upon any UK government (something Cameron did not do last time)?
It should.
The main problems with a second referendum are:
a) Bremain would win a second referendum with ease
b) A victory for Bremain and revoking article 50 would tear up the Tory party, that's why Tories are unlikely to ever support it
c) Corbyn is a life-long Brexitard, remaining in the EU would destroy his dream forever
d) Lots and lots of Brexit unicorns were promised, by Tories and Labour both, none of whom make it to the referendum I proposed above. If the referendum contains those unicorns it becomes unwieldy - three option aren't a problem, but seven are. Furthermore if one of those unicorns wins the situation is back to square one, but you already spent your best shot at solving the issue one way or the other.
To resolve Brexit without a no deal you'd need an epic climbdown, akin to, ugh, Alex Jones seeing the light, stop humping Trump's leg and become a registred Democrat. Imagine how hard that would be on him and how many followers he'd keep.
Tories are in about the same situation, Corbyn isn't far behind. That's the key problem of Brexit.
McHrozni