Method for modification of organic molecules