Riker grew a beard because the real Jonathan Frakes died in a plane crash between seasons one and two. Thankfully, Frakes's bearded twin brother, Jerry Frakes, agreed to step into the part, but asked to be billed in his brother's name, as a tribute. He agreed to play Riker exactly as his late brother did, but with one stipulation. He asked to keep the beard he had grown which was the only way his family could tell the two brothers apart. Roddenberry agreed.
No, they were actually triplets! The third one came on to play Thomas Riker in the 7th season episode "Second Chances"