Rear brake bleeds off.

I got on my bike tonight and used the rear brake to keep my bike from rolling down my driveway. After about 4 seconds of holding the pedal down the pedal would go down and the bike would start rolling. The bike was rolled backwards down a hill recently and this never happened before it rolled. It’s almost acting like there is air in the line. The bike is a ’14 sportsman 800. Any thoughts as to why my rear brake suddenly won’t keep pressure for more than 4 or 5 seconds?