I have to work with values such as 1e-15 in my code but I can't. Indeed, because of low precision these values are equivalent to 0. Any ideas?
The best thing to do would be to re-scale your problem so that way you don't have such small values. If you can, do this and call it a day.
If every number is small, then you can still be fine because of the subnormal floating point numbers. People mentioned this in the comments, and its addressed here:
However, subnormal numbers have slower calculations, so it's normal to try and avoid them. Also, because they are less than machine epsilon, they do not behave well (the easiest example is that if you add 1 to any of them, you get 1 back). The will multiply and add in ways that round the gaps, and you pay and extra cost for calculating with them.
So rescale your problem.
Or use quads, BigFloats, Arbs, 128-bit decimal floating point numbers. If you're using Julia, BigFloats are in Base, Arbs are in ArbFloats.jl, and decimals are in DecFP.jl. Due to type-genericity, you can generally replace any algorithm with these number types and it should just work (even in code from packages, if the author didn't overtype their functions).
But first, try rescaling your problem.