Simply put, yes. If the casino is licenced and regulated in the country that you are playing from, it is legal. Always make sure that the online casino you are using is regulated by the UK Gambling Commission and is regularly tested for fairness and legality operations by the relevant authorities.