Is there a way to add dependencies for a specific version?

Yes, you can do that: go to Project Settings > Dependencies, click on the + button and enter the name of the specific dependency with the specific version using @.
For example: [email protected]