The netplan configuration file located in /etc/netplan must contain:

network:
  version: 2
  renderer: networkd
  ethernets:
    enp3s0:
      dhcp4: true

to apply changes:

sudo netplan apply

Connect to the PC with the new IP and restart it:

sudo reboot