Variables of type document are used to store Document of Record,Adaptive Form attachment(s). These variables can then be used in Send Email component to send attachments via e-mail.
This video will highlight the use of document type variable to store the generated DoR and then use the document variable in send e-mail step of an AEM Workflow.