Derbyshire have confirmed they have agreed a three-year deal with Warwickshire wicketkeeper Richard Johnson.