It would certainly be illegal. In the UK it's against the law to keep British wild birds in a cage. But caging non-native species like budgerigars and other parrots? That's legal. Goldfinches - Siberian, Himalayan, Gouldian or zebra? That too is sanctioned by law. But the UK's European goldfinch? If you confined one of those you could be prosecuted.