The "Volume fit" rule attempts to pack as many product into as few packages possible by the calculated volume (Width x Height x Depth). This rule is a classic "bin-packing" algorithm with a NP-hard complexity meaning even with today's modern science, there is still no known efficient way to locate a solution by a computer without using brute force. Since 100% coverage by brute force is not always possible without overtaxing the server, the resulting solution is only a best guess approximation by a computer that is mostly accurate, but may not guarantee the most efficient way to pack. Only a human brain can perform this task effortlessly.
The algorithm tries to find the best fitting package(s) by matching the available volume of the package with the volume of the products as well as taking into consideration any package quantity restrictions, max weight, etc. The available volume of the package is reduced by the fill factor to allow for some empty space in real life packing (e.g if fill factor is 90%, it means the available space of the package is 90% of the volume of the internal package dimensions). If it cannot fit all in one package, it will overflow to the next package and so on. The algorithm will optimize for the least number of packages by favoring for larger packages over smaller ones (i.e. it will try to fit more into a large package to avoid splitting into many smaller ones). If no suitable package is found that can fit the smallest product, it will dynamically create a package to hold the product.