In the UK you need to make a reasonable effort to return it, and if it doesn't work then since 2019 you can apparently keep it although you presumably need to be prepared to return it if it's claimed later. Good article here: https://notlost.com/the-definitive-guide-to-lost-property-laws-in-the-uk/
Edit in response to a comment: The article acknowledges that the definition of "reasonable" is subjective. Personally I have two thoughts on this:
- Think "what's the worst that can happen?", could you be taken to court? Do you live in a regeneration area (also known as rough area) and intend on using the bike in the area a lot, and could you be beaten up by the original owner when he sees you on the bike and considers you the original thief?
- In a wider sense, any conversation about the definition of "reasonable" requires... well, reasonable people, and not everyone is.