Because youtube has brought this feature to its users. And by default playback in feeds is enabled on your youtube apps. This is the reason youtube videos play automatically while scrolling.