A VPN provides internet connectivity, therefore it is more like a partially broken internet connection instead of a firewall.
A VPN simply gives you access to a local network. A specific use of a VPN is masking your internet traffic as if it came from that local network, but there are many uses besides it.