Brexit: What is the Northern Ireland protocol and why is it needed?

What is the plan to avoid checks along the Irish border?