The Cobblers opened the scoring after four minutes when Diamond headed in from Danny Rose's corner.
Joe Piggott could have levelled for the Hatters but he failed to convert Pelly Ruddock's cross from close-range.
Marquis capped an excellent Northampton move by latching onto John-Joe O'Toole's delivery, before Sam Hoskins struck the post for the home side.
Chris Wilder's side were presented with the League Two trophy on the pitch at Sixfields after the final whistle.
Goals from Zander Diamond and John Marquis gave League Two champions Northampton victory over Luton.