Most VoIP (Voice over IP Phones) come with two network ports. One is for connecting to the wall (LAN) and the other is optional to provide a conneciton for a laptop or PC if there are not extra network ports.
In this way, both the phone and the computer are sharing the same network connection.
Source