Under the Blocks menu, go to Utility > Variables.‍
2. Enter a name for your variable, and hit Create. A new block containing your new variable will appear below.
3. Choose the block you want and drag it to the workspace.