Hello,
So, it seems like the script disables autoplay, and uses YouTube's iframe API - which also defaults to disabling autoplay. I would suggest checking other code on your page to ensure you aren't triggering a click event on the element with the embed.
Another thing to potentially check is if your browser settings or extensions cause autoplay to happen regardless. I would try with other browsers, such as Firefox to be sure the behavior is functioning as intended.
Without any code, my ability to help with your issue is limited a lot. It's one thing to specify the library you're using, but it's not of much help unless I see the code you're writing, too. If you could maybe upload the page that is experiencing this to your site temporarily, that way I can look into it?