I am a thin guy. How should I train and eat to gain lean muscle mass?
I have never worked out before and don’t gain weight easily. How do I bulk up?

Hypertrophy training will place your muscles under the greatest amount of tension and result in building and sustaining lean muscle mass. This is the type of training that bodybuilders use. You will use compound movements such as the squat, bench press, deadlift, pull-up and clean and press.
As a beginner, you should be working out 3 times a week with a day of rest in between sessions. All 3 sessions should be full body workouts as this will help to build the body evenly while correcting strength imbalances. Eventually, you will progress to 4 sessions a week and you will be able to begin performing upper and lower body splits. Here are acute variables to follow for each exercise:
Sets: 3
Repetitions: Between 8 and 12
Rest: 60 seconds - 90 seconds (if you superset exercises)
Tempo: 2 seconds concentric/1 second isometric / 2 seconds eccentric
Volume: 65%-75% of your one repetition maximum
When it comes to nutrition, being consistent and clean is the best way to go. Be sure to eat a balanced meal of protein, complex carbohydrates and fats every 2 to 3 hours. Supplement your muscles pre and post workout with a protein shake. Ideally, you want to consume between 0.6 grams and 0.8 grams of protein per pound of body-weight each day. Don't forget to drink plenty of water! 8 glasses a day is still the standard.
Lastly, keep changing up your training and nutrition plans. Keep it interesting that way you can avoid boredom.