"The boys have to learn how to stay at the crease for a long time"
This is the problem. They still feel that test matches are a 50 over game, and think that time is running out. They become restless after 5 overs and become impatient when the scoring is low. They have to be able to concentrate and stay at the crease for a long time even if the scoring is low. When they overcome this, then they will be able to carry a test match into the fourth day at least and not lose by an innings.
They are playing against teams and players who have had many more years of playing test matches than them.