How do I pass variables to a view builder's renderer?
This is not possible to add parameters to renderPlain(). What you can do depends. If you want to use a variable inside of the node, then do this in a node preprocess hook. But more likely you want to add additional elements to the build array before you render it, for example:

$build = [];
$build['top'] = ['#markup' =&gt; 'abc'];
$build['node'] = $view_builder-&gt;view($node, 'cnas_pdf');
$build['footer'] = ['#markup' =&gt; 'xyz'];