There are SO many different laws which you need to follow, for new dog owners it's hard to know where to start.
Dog owners need to comply with the Animal Welfare Act 2006 makes owners responsible for their dog’s welfare and specifically the five welfare needs. These fall into the categories of diet, freedom to exhibit normal behaviour, social contact, environment, and health. You could be prosecuted under this act for leaving your dog in a hot car for instance. However, the five needs can vary significantly between dogs and some owners could need the support of a professional to identify what is, for instance, the right amount of social contact or the right environment for their specific dog. Note that there is no formal requirement to exercise or train a dog. However, the Highway code requires dogs to be suitably restrained when travelling in a car.
The dog fouling act 2016 makes dogs responsible for clearing up fouling in all public places, apart from where it would be dangerous to do so e.g. on the side of a cliff edge. This means that owners need to carry poo bags and to pick up when they are out. With recent changes to council bins this may mean searching out a suitable bin or taking the poo home to dispose of.
Since 2016 all dogs have to be microchipped. This means that any reputable breeder should ensure their puppies are chipped. Where an informal adoption takes place and the dog was born before 2016 then the owners will need to check that the dog is chipped. Owners also need to ensure that their details are kept up to date on a register such as PetLog, however, there is more than one register. Stray dogs can be scanned and if the details on the register are up to date, returned to their owners.
All dogs must wear a collar with Identification tags or plates whenever they are in a public place according to the Control of Dogs Act 1992. Every dog while on a public highway or place of public resort must wear a collar with the name and address (including postcode) of the owner inscribed on it or a plate or badge attached to it. It is also advisable to have your telephone number as well so that you can be contacted in the event that someone finds your dog. Without a collar, your dog is more likely to be treated as a stray dog.
Under the Dangerous Dogs Act (DDA) 1991 owners need to keep their dogs under control in a public place and to ensure that members of the public or other owners are not fearful or apprehensive as a result of their dog. In reality this means that if an owner lets their dog off the lead then owners need to be able recall their dog. In addition, any dogs of a banned type (identified under the DDA) will need to be registered, neutered, kept on a lead and muzzled at all times when in a public place. There is no requirement for owner to attend any training unless a behavioural assessment is mandated under the DDA.
In addition, dogs should not be allowed to bark excessively such that it interferes unreasonably with the comfort of your neighbours. There are more, such as relates to worrying livestock but the above is a good starting point. As a new owner it's well worth looking up the Animal Welfare Act and the codes of practice for owners.