Is it possible to pass environment variables to multibranch pipeline job in a time of generating it via DSL? I want to pass some environment variables in the time of generating the multibranch pipelines, so upon the build start, it will already have these variables.

The only thing I found was this envInject plugin which is not supported by multibranch DSL generation.

https://jenkinsci.github.io/job-dsl-plugin/#plugin/envinject

Does anyone know the way to do that?
You can use Jenkins DSL and pass the environment variable as mentioned in below links:

https://jenkins.io/doc/book/pipeline/syntax/#environment
https://jenkins.io/doc/pipeline/steps/workflow-basic-steps/#withenv-set-environment-variables