Why adding SQL Server user to "Perform volume maintenance tasks" improves the speed of database resizing so much?
That's because of Instant File Initialization.  In short, SQL Server can take advantage of this privilege for database data files (not transaction log files).  What this means is that SQL Server does not have to zero out the data file(s) when initializing.

Without the "Perform volume maintenance tasks" privilege granted to the SQL Service account, upon the database creation SQL Server needs to zero out "test.mdf" and "test_log.ldf".

With the "Perform volume maintenance tasks" privilege permission set, SQL Server only needs to zero out "test_log.ldf".  A significantly less overhead, therefore minimized duration for the CREATE DATABASE in your testing.

References
How and Why to Enable Instant File Initialization
Instant Initialization – What, Why and How?