That's not possible with hashcat. What you are trying to create is a stupid version of a rainbow table. For fast hashes such as plain MD5 it's going to be faster to re-calculate the hashes than to store them and look them up. You'd end up with terabytes of occupied space.
edit: to back this up with some numbers:
an md5 hash has 16 bytes, lets say your average password has 10 characters/bytes and give four additional bytes for DBMS overhead per entry.
That would mean you can save 1000*1000*1000*1000/(16+10+4) = 33333333333 passwords per terabyte of space.
For MD5 a GTX1050Ti can calculate ~6037Mh/s
33333333333/(6037*1000*1000) = 5.5
That means for md5 one terabyte of space is equivalent to running hashcat for 5.5 seconds on a mid-range GPU. That only takes into consideration space, not the time you need to populate the database or to query it.
Slow hashes are usually using a salt which makes the whole thing even more useless.
edit: to back this up with some numbers:
an md5 hash has 16 bytes, lets say your average password has 10 characters/bytes and give four additional bytes for DBMS overhead per entry.
That would mean you can save 1000*1000*1000*1000/(16+10+4) = 33333333333 passwords per terabyte of space.
For MD5 a GTX1050Ti can calculate ~6037Mh/s
33333333333/(6037*1000*1000) = 5.5
That means for md5 one terabyte of space is equivalent to running hashcat for 5.5 seconds on a mid-range GPU. That only takes into consideration space, not the time you need to populate the database or to query it.
Slow hashes are usually using a salt which makes the whole thing even more useless.