I don't think you can adjust it with the stock messaging app. You can use a 3rd party messaging app like Textra though, and get that kind of customization. Textra offers a pop up over the lockscreen and you can adjust the amount of time it stays open. Hope this helps.