Hi confusedaccountant1989
The rules which determine if and where VAT is to be charged is the Place of Supply Rules.
If you are the customer of company A and you are in the UK then company A is making a supply within the UK and so would need to charge VAT.
Please see the information below:
6. The place of supply rules for services
Thank you.