In any case you need to create your own module. Whether to copy the code and tweak it or create your own implementation of some existing interface from scratch is up to you - this relies on your specific scenario and the extent of the tweaking needed.
There are a few ways to extend existing things in Orchard:
- Any service interface that implements
IDependency
can be overridden by simply putting your own implementation in your module OrchardSuppressDependency
attribute can be used on your class to explicitly disable certain existing implementations- Shape templates and normal views can be overridden in the theme as descibed in docs