McKinnon was also interviewed for the vacancy at St Mirren, but the Paisley club instead appointed Dumbarton's Ian Murray.
The 44-year-old has joined Rovers on a two-year contract.
Chief executive Eric Drysdale said: "Ray ticks all the boxes and we are confident he can take us forward."
Rovers were seeking a new manager after Grant Murray, who had been in charge for three years, was sacked in April following five straight defeats.
Now Malpas, the 52-year-old former Motherwell and Swindon Town manager who had been in his role since December, has also left the Kirkcaldy club.
"As promised, the board has taken great care in its search for someone to replace Grant Murray," said Drysdale.
"We spoke in detail to four of the very best candidates from a very long list of applicants.
"Only one, Ray, was formally offered the job and we are very pleased that he has accepted."
Former Rovers player McKinnon, who previously managed junior club Lochee United, recently signed a new contract at Glebe Park.
First-team coach Laurie Ellis took charge of the Kirkcaldy side for the final Scottish Championship match of the season - a 2-2 draw away to Dumbarton - as they finished in sixth place.
McKinnon, who took over as Brechin boss in 2012, led his side to a fourth-place finish in League One this season.
However, they missed out on promotion after losing 2-1 on aggregate to Alloa Athletic in their play-off semi-final.
McKinnon, who began his career at Tannadice, had two spells as a player at Stark's Park.
He made five appearances in 2000 after leaving Livingston before joining Portadown, and Rovers were his final senior club, making 12 appearances in 2003 after leaving Montrose.
McKinnon also had spells with Nottingham Forest, Luton Town, Stirling Albion, East Fife and Torquay United and finished his career in junior football with Lochee and Broughty Athletic.
Ray McKinnon has left Brechin City to become Raith Rovers manager, with Maurice Malpas standing down as director of football at Stark's Park.