Renewables made up a record 41.5% of electricity generation in the UK during 2022, as both wind and solar reached record levels.